pending.nvim/lua/pending/sync
Barrett Ruth 90f1378cb6 refactor(sync): centralize with_token in oauth.lua with shared lock
Problem: `with_token` was duplicated in `gcal.lua` and `gtasks.lua`,
with the concurrency lock added only to the gtasks copy. Any new
backend would silently inherit the same race, and gcal back-to-back
push could still create duplicate remote calendar events.

Solution: lift `with_token` into `oauth.lua` as
`M.with_token(client, name, callback)` behind a module-level
`_sync_in_flight` guard. All backends share one implementation; the
lock covers gcal, gtasks, and any future backend automatically.
2026-03-06 16:03:46 -05:00
..
gcal.lua refactor(sync): centralize with_token in oauth.lua with shared lock 2026-03-06 16:03:46 -05:00
gtasks.lua refactor(sync): centralize with_token in oauth.lua with shared lock 2026-03-06 16:03:46 -05:00
oauth.lua refactor(sync): centralize with_token in oauth.lua with shared lock 2026-03-06 16:03:46 -05:00