diff options
| author | Adam Soltys <[email protected]> | 2021-04-23 00:44:23 -0400 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2021-04-27 18:07:15 -0400 |
| commit | 20273701d1cf75ef7540ba2e7b90554c0b17c41c (patch) | |
| tree | 3543e736c52a6d39253c5f3e1266abe565477e0e | |
| parent | 2621fec1c189b6de5e3bd2b86b391443ccd7a8a7 (diff) | |
| download | coinos-server-20273701d1cf75ef7540ba2e7b90554c0b17c41c.tar.gz coinos-server-20273701d1cf75ef7540ba2e7b90554c0b17c41c.zip | |
change cors setting
| -rw-r--r-- | index.js | 2 | ||||
| -rw-r--r-- | package.json | 2 | ||||
| -rw-r--r-- | routes/payments.js | 2 | ||||
| -rw-r--r-- | routes/users.js | 3 |
4 files changed, 4 insertions, 5 deletions
@@ -52,7 +52,7 @@ app.use((err, req, res, next) => { return res.end(); }); app.use(cookieParser()); -// app.use(cors({ credentials: true, origin: "http://*:*" })); +app.use(cors({ credentials: true, origin: "https://coinos.io" })); app.use(compression()); server = require("http").Server(app); diff --git a/package.json b/package.json index cb568e53..73b43918 100644 --- a/package.json +++ b/package.json @@ -61,7 +61,7 @@ "devDependencies": { "nodemon": "^2.0.2", "pino-pretty": "^3.6.1", - "pm2": "^4.4.1", + "pm2": "^4.5.6", "prettier": "^1.18.2" } } diff --git a/routes/payments.js b/routes/payments.js index e8c82853..00eb1bb2 100644 --- a/routes/payments.js +++ b/routes/payments.js @@ -68,7 +68,7 @@ ah(async () => { tx => tx.category === "receive" && tx.confirmations > 0 && - unconfirmed.includes(tx.address) + unconfirmed.includes(tx.txid) ) .map(tx => { l.warn("tx unconfirmed in db", tx.txid, tx.address); diff --git a/routes/users.js b/routes/users.js index d6dc68a7..47964887 100644 --- a/routes/users.js +++ b/routes/users.js @@ -337,8 +337,7 @@ app.post( ) { l.warn( "invalid username or password attempt", - req.body.username, - req.body.password + req.body.username ); return res.status(401).end(); } |
