Registration improved errors

Added some checks around IAuthRepository initialization to throw helpful errors.