Skip to content

Commit

Permalink
Merge pull request TryGhost#1882 from jgillich/fix
Browse files Browse the repository at this point in the history
Fix TypeError due to missing mail config
  • Loading branch information
ErisDS committed Jan 7, 2014
2 parents 5a638ed + f8299ed commit 371dc86
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/server/update-check.js
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ function updateCheckData() {
data.node_version = process.versions.node;
data.env = process.env.NODE_ENV;
data.database_type = require('./models/base').client;
data.email_transport = mailConfig && mailConfig.options && mailConfig.options.service ? mailConfig.options.service : mailConfig.transport;
data.email_transport = mailConfig && (mailConfig.options && mailConfig.options.service ? mailConfig.options.service : mailConfig.transport);

return when.settle(ops).then(function (descriptors) {
var hash = descriptors[0].value,
Expand Down Expand Up @@ -188,4 +188,4 @@ function updateCheck(res) {
return deferred.promise;
}

module.exports = updateCheck;
module.exports = updateCheck;

0 comments on commit 371dc86

Please sign in to comment.