Просмотр исходного кода

use packs only for temporary ops

Brian Gough 10 лет назад
Родитель
Сommit
84ace7f4c7
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      services/track-changes/app/coffee/UpdatesManager.coffee

+ 1 - 1
services/track-changes/app/coffee/UpdatesManager.coffee

@@ -47,7 +47,7 @@ module.exports = UpdatesManager =
 			if rawUpdates.length == 0
 				return callback()
 
-			if not lastCompressedUpdate? or lastCompressedUpdate.pack? # handle pack append as a special case
+			if temporary and (not lastCompressedUpdate? or lastCompressedUpdate.pack?) # handle pack append as a special case
 				UpdatesManager._updatePack project_id, doc_id, rawUpdates, temporary, lastCompressedUpdate, lastVersion, callback
 			else #use the existing op code
 				UpdatesManager._updateOp project_id, doc_id, rawUpdates, temporary, lastCompressedUpdate, lastVersion, callback