- lint fixes

This commit is contained in:
Ulf Gebhardt 2021-01-22 17:38:54 +01:00
parent cd42824502
commit c420e18543
No known key found for this signature in database
GPG Key ID: 81308EFE29ABFEBD

View File

@ -37,17 +37,17 @@ const isMySocialMedia = rule({
cache: 'no_cache',
})(async (_, args, { user }) => {
// We need a User
if (!user){
if (!user) {
return false
}
let socialMedia = await neode.find('SocialMedia', args.id)
// Did we find a social media node?
if(!socialMedia){
if (!socialMedia) {
return false
}
socialMedia = await socialMedia.toJson() // whats this for?
//Is it my social media entry?
// Is it my social media entry?
return socialMedia.ownedBy.node.id === user.id
})