Merge pull request #20317 from overleaf/em-github-sync-errors

Replace alerts with notifications in the github-sync modal

GitOrigin-RevId: 772add41b2d525353dc0c0362ebc64c4a023e2c3
This commit is contained in:
Eric Mc Sween
2024-09-19 08:21:51 -04:00
committed by Copybot
parent bed8ddd172
commit d54d5f1eb6

View File

@@ -19,7 +19,11 @@ export const useScope = (scope: Record<string, unknown>) => {
} catch {
// allowed not to exist
}
window.overleaf.unstable.store.set(path, merge(existingValue, value))
if (typeof existingValue === 'object' && typeof value === 'object') {
window.overleaf.unstable.store.set(path, merge(existingValue, value))
} else {
window.overleaf.unstable.store.set(path, value)
}
}
}
}, [])