Fixed cleartext login under specific conditions

A user was looked up in the wrong database with binding marked as
inactive