AuthResponse.from constructor

AuthResponse.from({
  1. required int statusCode,
  2. required String reasonPhrase,
  3. required Map<String, String> headers,
  4. required String username,
  5. required String userId,
  6. required AuthError? error,
})

Returns the new instance of AuthResponse based on arguments.

Implementation

AuthResponse.from({
  required int statusCode,
  required String reasonPhrase,
  required Map<String, String> headers,
  required this.username,
  required this.userId,
  required this.error,
}) : super.from(
        status: Status.from(
          code: statusCode,
          reasonPhrase: reasonPhrase,
        ),
        headers: headers,
      );