Skip to content

Commit

Permalink
code refactoring.
Browse files Browse the repository at this point in the history
  • Loading branch information
xsami committed Oct 15, 2019
1 parent b307230 commit b281e27
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions models/friend.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,7 @@ func ValidateFriendShip(friends []Friend, userIDA int, userIDB int) bool {
(f.UserIDFrom == userIDB && f.UserIDTo == userIDA))
})

if len(resultFriends) > 0 {
return true
}

return false
return len(resultFriends) > 0
}

// GetFriendsID return a list of IDs
Expand Down

0 comments on commit b281e27

Please sign in to comment.