aboutsummaryrefslogtreecommitdiffstats
path: root/routes
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2020-03-19 22:57:04 -0700
committerAdam Soltys <[email protected]>2020-03-19 22:57:04 -0700
commit05ac54f58238b56534e3d2bd638af0613834a06d (patch)
treea6ae190f834e0278ed9057f22c590cbff01b880c /routes
parent49065ec0b491c90887b51556a836993e719eb26f (diff)
downloadcoinos-server-05ac54f58238b56534e3d2bd638af0613834a06d.tar.gz
coinos-server-05ac54f58238b56534e3d2bd638af0613834a06d.zip
update readme
Diffstat (limited to 'routes')
-rw-r--r--routes/users.js6
1 files changed, 1 insertions, 5 deletions
diff --git a/routes/users.js b/routes/users.js
index d65c888f..368cca6c 100644
--- a/routes/users.js
+++ b/routes/users.js
@@ -83,7 +83,7 @@ app.post("/register", async (req, res) => {
GB: "GBP"
};
- if (ip.startsWith("127") || ip.startsWith("192")) user.currency = "CAD";
+ if (!config.ipstack || ip.startsWith("127") || ip.startsWith("192")) user.currency = "CAD";
else {
let info = await axios.get(
`http://api.ipstack.com/${ip}?access_key=${config.ipstack}`
@@ -262,10 +262,6 @@ app.post("/facebookLogin", async (req, res) => {
let friends = (await axios.get(
`${fb}/${userID}/friends?access_token=${accessToken}`
)).data.data;
- if (friends.find(f => f.id === config.facebook.specialFriend)) {
- user.friend = true;
- user.limit = 200;
- }
await user.save();
addresses[user.address] = user.username;
addresses[user.liquid] = user.username;