Very hard to answer without any context, but this is what it actually does (it does what we call in Javascript a 'double bang' and an OR):
B4X:
Sub CheckPassword(v As Object) As Object
Return Not(Not(v)) Or "Password is required"
End Sub
...
Log(CheckPassword("")) ' Password is required
Log(CheckPassword(True)) 'true
Log(CheckPassword(False)) ' Password is required
Log(CheckPassword("Password")) ' true