diff --git a/ddoc.js b/ddoc.js
index <HASH>..<HASH> 100644
--- a/ddoc.js
+++ b/ddoc.js
@@ -102,7 +102,7 @@ function validate_doc_update(newDoc, oldDoc, userCtx, secObj) {
     if(newDoc.Body === null || newDoc.Body === undefined)
       throw {forbidden: 'Invalid .Body: ' + JSON.stringify(newDoc.Body)};
   } else {
-    if(oldDoc.ReceiverId !== userCtx.name) {
+    if(!oldDoc || oldDoc.ReceiverId !== userCtx.name) {
       if(IS_DB_ADMIN)
         log('Allowing db admin "'+userCtx.name+'" to delete: ' + newDoc._id);
       else
Protect against missing old docs when replicating