Skip to content

Node.js based forum software built for the modern web

fix: handle missing timestamps

Barış Soner Uşaklı172e688805ad
diff --git a/src/upgrades/1.12.1/moderation_notes_refactor.js b/src/upgrades/1.12.1/moderation_notes_refactor.js
index 914d7f43d6..0bc17846ba 100644
--- a/src/upgrades/1.12.1/moderation_notes_refactor.js
+++ b/src/upgrades/1.12.1/moderation_notes_refactor.js
@@ -25,6 +25,7 @@ module.exports = {
function (next) {
try {
noteData = JSON.parse(note);
+ noteData.timestamp = noteData.timestamp || Date.now();
setImmediate(next);
} catch (err) {
next(err);