Skip to content

Commit 0ee506a

Browse files
committed
added isp and collect typo
1 parent 43e2d7c commit 0ee506a

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

client/index.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,11 @@ function getIfDeviceInAcceleration(x,y,z) {
9292
}
9393
}
9494

95-
async function collectHASH(sha) {
95+
async function collectHASH(sha, meta) {
96+
meta = JSON.stringify(meta)
97+
meta = btoa(meta)
9698
const response = await fetch("https://mycookie-monster.herokuapp.com/collect-sha/"+sha, {
97-
headers: {'Content-Type': 'application/json'},
99+
headers: {'Content-Type': 'application/json', 'metadata': meta},
98100
method: 'GET',
99101
})
100102
return response.json()

index.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ const Item = sequelize.define("Item", {
2020
memory: {type: DataTypes.STRING, allowNull: true},
2121
platform: {type: DataTypes.STRING, allowNull: true},
2222
hardwareConcurrency: {type: DataTypes.STRING, allowNull: true},
23+
isp: {type: DataTypes.STRING, allowNull: true},
2324
})
2425

2526
const {

0 commit comments

Comments
 (0)