returning false positive in checkCredentials