Skip to content

Node.js based forum software built for the modern web

fixing possible crash

Julian Lam3b6b36cfa641
diff --git a/src/messaging.js b/src/messaging.js
index 7d3a89316e..81758f43b7 100644
--- a/src/messaging.js
+++ b/src/messaging.js
@@ -390,7 +390,7 @@ var db = require('./database'),
count: 1,
markRead: false
}, function(err, teaser) {
- teaser = teaser[0];
+ var teaser = teaser[0];
teaser.content = S(teaser.content).stripTags().decodeHTMLEntities().s;
next(err, teaser);
});