aboutsummaryrefslogtreecommitdiffstats
path: root/lib/utils.js
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2022-12-28 10:42:45 -0800
committerAdam Soltys <[email protected]>2022-12-28 10:42:45 -0800
commitddb9a4350c56889f5c639d8a689d054fd6791af2 (patch)
treedb1604e13a0d4847eaf919982c844339157037ef /lib/utils.js
parent27778aeb6ff2dfd016588f15f97afa1632cd68cf (diff)
parentdf3f91fbc6d0b75c4c875c787d8ab29b2f1d2768 (diff)
downloadcoinos-server-ddb9a4350c56889f5c639d8a689d054fd6791af2.tar.gz
coinos-server-ddb9a4350c56889f5c639d8a689d054fd6791af2.zip
Merge remote-tracking branch 'origin/prod'
Diffstat (limited to 'lib/utils.js')
-rw-r--r--lib/utils.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/utils.js b/lib/utils.js
index 49f95a00..6a4bc1b2 100644
--- a/lib/utils.js
+++ b/lib/utils.js
@@ -65,7 +65,7 @@ export const getUser = async (username, transaction) => {
});
await wait(() => !store.fetching[pubkey], 100, 10);
- user.follows = JSON.parse(await redis.get(`${pubkey}:follows`));
+ user.follows = JSON.parse(await redis.get(`${pubkey}:follows`)) || [];
user.followers = await redis.sMembers(`${pubkey}:followers`);
}