Updated login / register validation.