Comparing version 1.0.0 to 1.1.0
11
index.js
@@ -53,2 +53,13 @@ 'use strict'; | ||
/** | ||
* 发送 Alert | ||
* | ||
* @param {String} title 发送标题 | ||
* @param {Stringany} content 发送内容 | ||
* @param {boolean} [urgency=false] 是否紧急 | ||
* @param {String} [receiver=this.receiver] 接收组 | ||
* @param {String} [source=this.source] 发送源 | ||
* @returns {Promise} | ||
* @memberof AlertOver | ||
*/ | ||
send(title, content, urgency = false, receiver = this.receiver, source = this.source) { | ||
@@ -55,0 +66,0 @@ const data = { |
{ | ||
"name": "alertover", | ||
"version": "1.0.0", | ||
"description": "AlertOver (https://www.alertover.com ) cliet for Node.js", | ||
"version": "1.1.0", | ||
"description": "AlertOver (https://www.alertover.com ) client for Node.js", | ||
"main": "index.js", | ||
@@ -14,3 +14,11 @@ "scripts": { | ||
"author": "Yourtion <yourtion@gmail.com>", | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/yourtion/node-alertover.git" | ||
}, | ||
"bugs": { | ||
"url": "https://github.com/yourtion/node-alertover/issues" | ||
}, | ||
"homepage": "https://github.com/yourtion/node-alertover#readme", | ||
"license": "MIT" | ||
} |
@@ -6,6 +6,6 @@ 'use strict'; | ||
const client = new AlertOver({ | ||
source: '', | ||
receiver: '', | ||
source: process.env.ALERT_SOURCE, | ||
receiver: process.env.ALERT_RECEIVER, | ||
}) | ||
client.send('Hello', 'World').then(console.log).catch(console.log) | ||
client.send('Hello', 'World').then(console.log).catch(console.log); |
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 2 instances in 1 package
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
5774
6
84
1
1
1
40
2