fix(jira-knowledge): save config before sync to prevent stale base URL error
_trigger_sync reads jira config from self.ctx.config.data, but if the user hasn't clicked Save yet the config still holds old/empty values. Add self._save() at the top of _trigger_sync so the current form values (base URL, email, token, project mapping) are persisted to config before the background sync job reads them. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -235,6 +235,9 @@ class JiraConnectDialog(QDialog):
|
||||
|
||||
def _trigger_sync(self) -> None:
|
||||
"""Trigger a background sync job using JiraSyncService."""
|
||||
# Save current form values to config before syncing — otherwise the
|
||||
# sync job reads stale/empty config if the user hasn't clicked Save yet.
|
||||
self._save()
|
||||
self.sync_status.setText(tr("connectors.jira_kb_syncing"))
|
||||
self.sync_btn.setEnabled(False)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user