Skip to content
This repository was archived by the owner on Nov 27, 2023. It is now read-only.

Commit 4a6bee9

Browse files
committed
Improve logic readability
1 parent 0d88ddb commit 4a6bee9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/lib/orbitdb-api.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,8 +265,9 @@ class OrbitdbAPI {
265265
method: ['POST', 'PUT'],
266266
path: '/db/{dbname}/access/write',
267267
handler: dbMiddleware( async (db, request, _h) => {
268-
if (await db.access.grant('write', request.payload.id) !== false) return {}
268+
if (await db.access.grant('write', request.payload.id) === false)
269269
return new Boom.notImplemented('Access controller does not support setting write access');
270+
return {}
270271
})
271272
},
272273
{

0 commit comments

Comments
 (0)