mirror of
https://github.com/overleaf/overleaf.git
synced 2025-03-02 23:23:38 +00:00
make flush to track-changes failsafe
This commit is contained in:
parent
dcd7649bad
commit
65cf4cf7c7
1 changed files with 3 additions and 2 deletions
|
@ -13,8 +13,9 @@ module.exports = HistoryManager =
|
|||
return
|
||||
RedisManager.getHistoryType doc_id, (err, projectHistoryType) ->
|
||||
if err?
|
||||
logger.error {err, doc_id}, "error getting history type"
|
||||
else if projectHistoryType is "project-history"
|
||||
logger.warn {err, doc_id}, "error getting history type"
|
||||
# if there's an error continue and flush to track-changes for safety
|
||||
if projectHistoryType is "project-history"
|
||||
logger.debug {doc_id, projectHistoryType}, "skipping track-changes flush"
|
||||
else
|
||||
url = "#{Settings.apis.trackchanges.url}/project/#{project_id}/doc/#{doc_id}/flush"
|
||||
|
|
Loading…
Reference in a new issue