From f910e63e903af890307acbb17be1ec9587c38782 Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Mon, 24 Aug 2015 12:22:17 -0300 Subject: [PATCH] fix null case --- services/track-changes/app/coffee/UpdatesManager.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/track-changes/app/coffee/UpdatesManager.coffee b/services/track-changes/app/coffee/UpdatesManager.coffee index 7e89be9ea3..38c97144a0 100644 --- a/services/track-changes/app/coffee/UpdatesManager.coffee +++ b/services/track-changes/app/coffee/UpdatesManager.coffee @@ -36,7 +36,7 @@ module.exports = UpdatesManager = MongoManager.insertCompressedUpdates project_id, doc_id, compressedUpdates, temporary,(error) -> return callback(error) if error? logger.log project_id: project_id, doc_id: doc_id, rawUpdatesLength: length, compressedUpdatesLength: compressedUpdates.length, "compressed doc updates" - if lastCompressedUpdate.inS3? + if lastCompressedUpdate?.inS3? MongoManager.remarkDocHistoryAsArchived doc_id, callback else callback()