mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Added sentry_dsn
and sentry_env
properties to /canary/site/
refs https://github.com/TryGhost/Team/issues/723 - enables Admin to report unhandled exceptions and API errors when configured
This commit is contained in:
parent
367b1a509f
commit
5fe9036ecf
2 changed files with 9 additions and 1 deletions
|
@ -14,7 +14,9 @@ module.exports = {
|
||||||
'accent_color',
|
'accent_color',
|
||||||
'url',
|
'url',
|
||||||
'version',
|
'version',
|
||||||
'oauth'
|
'oauth',
|
||||||
|
'sentry_dsn',
|
||||||
|
'sentry_env'
|
||||||
])
|
])
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
const ghostVersion = require('../../lib/ghost-version');
|
const ghostVersion = require('../../lib/ghost-version');
|
||||||
const settingsCache = require('../settings/cache');
|
const settingsCache = require('../settings/cache');
|
||||||
|
const config = require('../../../shared/config');
|
||||||
const urlUtils = require('../../../shared/url-utils');
|
const urlUtils = require('../../../shared/url-utils');
|
||||||
|
|
||||||
module.exports = function getSiteProperties() {
|
module.exports = function getSiteProperties() {
|
||||||
|
@ -18,5 +19,10 @@ module.exports = function getSiteProperties() {
|
||||||
siteProperties.oauth = true;
|
siteProperties.oauth = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (config.get('client_sentry') && !config.get('client_sentry').disabled) {
|
||||||
|
siteProperties.sentry_dsn = config.get('client_sentry').dsn;
|
||||||
|
siteProperties.sentry_env = config.get('env');
|
||||||
|
}
|
||||||
|
|
||||||
return siteProperties;
|
return siteProperties;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Reference in a new issue