Skip to content

Commit 8fa6e71

Browse files
committed
Updates
1 parent e25599f commit 8fa6e71

2 files changed

Lines changed: 8 additions & 1 deletion

File tree

src/api.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,11 @@ export async function getVTReleaseStats(req) {
167167
/**
168168
* Get VT Stats for a File ID/Hash
169169
* @param {string} hash
170-
* @return {Promise<object>}
170+
* @typedef {object} Stats
171+
* @property {number} malicious
172+
* @property {number} suspicious
173+
* @property {number} undetected
174+
* @return {Promise<Stats>}
171175
*/
172176
export async function getVTStats(hash) {
173177
const key = `/vt/id/${hash}`

src/app.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,8 @@ app.get('/', async (req, res) => {
8686
links: {
8787
Source: 'https://github.com/smashedr/node-badges',
8888
Docs: 'https://smashedr.github.io/node-badges-docs',
89+
Grafana:
90+
'https://cssnr.grafana.net/public-dashboards/8a24a95171fe4127ada92afb071b9331',
8991
},
9092
// badges: [{ src: '', href: '' }],
9193
})
@@ -110,6 +112,7 @@ app.get('/colors{/:index}', async (req, res) => {
110112
debug('index:', index)
111113
const color = getRangedColor(req, index)
112114
debug('color:', color)
115+
// noinspection HtmlRequiredLangAttribute
113116
res.send(`<html><body style="margin:0;background:${color}"></body></html>`)
114117
})
115118

0 commit comments

Comments
 (0)