fixed find user by email case insensitive and fixed npe. resolves #158