mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-05-29 20:11:32 +02:00
avoid unnecessary call to insert packs into index
This commit is contained in:
@@ -261,7 +261,7 @@ module.exports = PackManager =
|
||||
# find all packs prior to current pack
|
||||
PackManager.findUnindexedPacks project_id, doc_id, (err, newPacks) ->
|
||||
return callback(err) if err?
|
||||
return callback() if not newPacks?
|
||||
return callback() if not newPacks? or newPacks.length is 0
|
||||
PackManager.insertPacksIntoIndexWithLock project_id, doc_id, newPacks, (err) ->
|
||||
return callback(err) if err?
|
||||
logger.log {project_id, doc_id, newPacks}, "added new packs to index"
|
||||
|
||||
Reference in New Issue
Block a user