added existing username handling and wrong credentials handling