@tryghost/bootstrap-socket: Switch to @tryghost/logging from injected arg

refs: https://github.com/TryGhost/Toolbox/issues/146
This commit is contained in:
Sam Lord 2021-12-02 12:35:36 +00:00
parent e1cc803ca3
commit cd9e295ec8
2 changed files with 6 additions and 1 deletions

View File

@ -1,4 +1,6 @@
module.exports.connectAndSend = (socketAddress, logging, message) => {
const logging = require('@tryghost/logging');
module.exports.connectAndSend = (socketAddress, message) => {
// Very basic guard against bad calls
if (!socketAddress || !socketAddress.host || !socketAddress.port || !logging || !logging.info || !logging.warn || !message) {
return Promise.resolve();

View File

@ -23,5 +23,8 @@
"mocha": "9.1.3",
"should": "13.2.3",
"sinon": "11.1.2"
},
"dependencies": {
"@tryghost/logging": "^1.0.2"
}
}