Fixed type-casting for AuthComponent::login()