summaryrefslogtreecommitdiff
path: root/app.js
diff options
context:
space:
mode:
Diffstat (limited to 'app.js')
-rw-r--r--app.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/app.js b/app.js
index b99a8e8b..bfb9ac7d 100644
--- a/app.js
+++ b/app.js
@@ -407,7 +407,7 @@ app.post('/uploadimage', function (req, res) {
if (config.debug)
logger.info('SERVER uploadimage success: ' + JSON.stringify(json));
res.send({
- link: json.data.link
+ link: json.data.link.replace(/^http:\/\//i, 'https://')
});
})
.catch(function (err) {
@@ -473,5 +473,8 @@ models.sequelize.sync().then(startListen);
// log uncaught exception
process.on('uncaughtException', function (err) {
+ logger.error('An uncaught exception has occured.');
logger.error(err);
+ logger.error('Process will exit now.');
+ process.exit(1);
}); \ No newline at end of file