aboutsummaryrefslogtreecommitdiffstats
path: root/lib/utils.js
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2022-12-28 10:48:45 -0800
committerAdam Soltys <[email protected]>2022-12-28 10:48:45 -0800
commit581a905b2fc14240d0bcbe6e2c14023fae3589a4 (patch)
treee79a6743c0537fb606ea3502a6d883c46f7813be /lib/utils.js
parentddb9a4350c56889f5c639d8a689d054fd6791af2 (diff)
downloadcoinos-server-581a905b2fc14240d0bcbe6e2c14023fae3589a4.tar.gz
coinos-server-581a905b2fc14240d0bcbe6e2c14023fae3589a4.zip
always define follows
Diffstat (limited to 'lib/utils.js')
-rw-r--r--lib/utils.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/utils.js b/lib/utils.js
index 6a4bc1b2..17283836 100644
--- a/lib/utils.js
+++ b/lib/utils.js
@@ -65,10 +65,11 @@ export const getUser = async (username, transaction) => {
});
await wait(() => !store.fetching[pubkey], 100, 10);
- user.follows = JSON.parse(await redis.get(`${pubkey}:follows`)) || [];
- user.followers = await redis.sMembers(`${pubkey}:followers`);
}
+ user.follows = JSON.parse(await redis.get(`${pubkey}:follows`)) || [];
+ user.followers = await redis.sMembers(`${pubkey}:followers`);
+
return user;
};
@@ -203,4 +204,3 @@ export const derivePayRequest = async ({ amount, memo, tip }) => {
await ln.invoice(value ? `${value}sat` : "any", new Date(), memo, 360)
).bolt11;
};
-