diff --git a/lib/msgDB.js b/lib/msgDB.js
index <HASH>..<HASH> 100644
--- a/lib/msgDB.js
+++ b/lib/msgDB.js
@@ -362,7 +362,7 @@ function addTimestampOps (state, update, batch) {
     if (isNewOrEdit) {
       batch.push({
         type: 'put',
-        key: getChainTimestampKey(update),
+        key: getChainTimestampKey(state),
         value: entryKey
       })
     } else if (utils.getEntryProp(state, 'dateChained') ||
@@ -380,7 +380,7 @@ function addTimestampOps (state, update, batch) {
     if (isNewOrEdit) {
       batch.push({
         type: 'put',
-        key: getSendTimestampKey(update),
+        key: getSendTimestampKey(state),
         value: entryKey
       })
     } else if (utils.getEntryProp(state, 'dateSent') ||
prevent timestamp override in send/chain queue