Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: file not synced after switch sync method -[INS-4347] #7897

Merged
merged 1 commit into from
Sep 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/insomnia/src/ui/routes/git-actions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ export const canPushLoader: LoaderFunction = async ({ params }): Promise<GitCanP
try {
canPush = await GitVCS.canPush(gitRepository.credentials);
// update workspace meta with git sync data, use for show unpushed changes on collection card
models.workspaceMeta.update(workspaceMeta, {
models.workspaceMeta.updateByParentId(workspaceId, {
hasUnpushedChanges: canPush,
});
} catch (err) { }
Expand Down
2 changes: 1 addition & 1 deletion packages/insomnia/src/ui/routes/request.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ export const loader: LoaderFunction = async ({ params }): Promise<RequestLoaderD
const activeWorkspaceMeta = await models.workspaceMeta.getByParentId(workspaceId);
invariant(activeWorkspaceMeta, 'Active workspace meta not found');
// NOTE: loaders shouldnt mutate data, this should be moved somewhere else
await models.workspaceMeta.update(activeWorkspaceMeta, { activeRequestId: requestId });
await models.workspaceMeta.updateByParentId(workspaceId, { activeRequestId: requestId });
if (isGrpcRequestId(requestId)) {
return {
activeRequest,
Expand Down
Loading