Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
Growl.prototype.notify = function(options, callback) {
growly.setHost(this.options.host, this.options.port);
options = utils.clone(options || {});
if (typeof options === 'string') {
options = { title: 'node-notifier', message: options };
}
callback = utils.actionJackerDecorator(this, options, callback, function(
data
) {
if (data === 'click') {
return 'click';
}
if (data === 'timedout') {
return 'timeout';
}
return false;
Growl.prototype.notify = function(options, callback) {
growly.setHost(this.options.host, this.options.port);
options = utils.clone(options || {});
if (typeof options === 'string') {
options = { title: 'node-notifier', message: options };
}
callback = utils.actionJackerDecorator(this, options, callback, function(
data
) {
if (data === 'click') {
return 'click';
}
if (data === 'timedout') {
return 'timeout';
}
return false;
async setup() {
for ( let port of ports ) {
try {
await NotificationProviderGrowl.checkConnection( port );
growly.setHost( host, port );
await NotificationProviderGrowl.register();
return;
} catch ( e ) {}
}
throw new Error( "Could not find growl server" );
}