added support of custom login\register methods