don't log doc contents if file is unchanged.

This commit is contained in:
Oliver Matthews 2014-03-06 10:53:59 +00:00
parent f781001280
commit b73d7f23c3

View file

@ -217,7 +217,7 @@ module.exports = ProjectEntityHandler =
logger.err "error putting doc #{doc_id} in project #{project_id} #{err}" logger.err "error putting doc #{doc_id} in project #{project_id} #{err}"
callback err callback err
else if docComparitor.areSame docLines, doc.lines else if docComparitor.areSame docLines, doc.lines
logger.log sl_req_id: sl_req_id, docLines:docLines, project_id:project_id, doc_id:doc_id, rev:doc.rev, "old doc lines are same as the new doc lines, not updating them" logger.log sl_req_id: sl_req_id, project_id:project_id, doc_id:doc_id, rev:doc.rev, "old doc lines are same as the new doc lines, not updating them"
callback() callback()
else else
logger.log sl_req_id: sl_req_id, project_id:project_id, doc_id:doc_id, docLines: docLines, oldDocLines: doc.lines, rev:doc.rev, "updating doc lines" logger.log sl_req_id: sl_req_id, project_id:project_id, doc_id:doc_id, docLines: docLines, oldDocLines: doc.lines, rev:doc.rev, "updating doc lines"