aboutsummaryrefslogtreecommitdiffstats
path: root/index.js
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2022-10-07 21:10:48 -0700
committerAdam Soltys <[email protected]>2022-10-07 21:10:48 -0700
commit756017c5bf6b1858c231d39670b217a606f4e454 (patch)
treed5eb774ac6c83ff2079766ba2a1f65ce3dd64c31 /index.js
parent0eb3dcabf63cda38dec86f9b3d4accac6c057f4d (diff)
downloadcoinos-server-756017c5bf6b1858c231d39670b217a606f4e454.tar.gz
coinos-server-756017c5bf6b1858c231d39670b217a606f4e454.zip
fix liquid asset receiving
Diffstat (limited to 'index.js')
-rw-r--r--index.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/index.js b/index.js
index c96abe5f..06338fbc 100644
--- a/index.js
+++ b/index.js
@@ -3,6 +3,7 @@ import persist from "./lib/persist";
import config from "./config/index";
import store from "./lib/store";
import { l, err } from "./lib/logging";
+import { optionalAuth } from "$lib/passport";
import "./db";
import "./lib/sockets";
@@ -28,7 +29,8 @@ if (config.lna) store.networks.push("lightning");
let host = process.env.HOST || "0.0.0.0";
let port = process.env.PORT || 3119;
-app.post('/echo', async (req, res) => {
+app.post('/echo', optionalAuth, async (req, res) => {
+ console.log(req.user.username)
console.log(req.body)
res.send(req.body);
});