prosodyctl: Fix import of util.iterators
[prosody.git] / util / sasl / scram.lua
index aad33ebcaafd45791ecdde7466f2fb3714564543..055ba16a7d551e3448e04358d34737b9b4b15b18 100644 (file)
@@ -90,7 +90,7 @@ local function validate_username(username)
        
        -- apply SASLprep
        username = saslprep(username);
-       return username;
+       return username and #username>0 and username;
 end
 
 local function hashprep(hashname)