copyWith method

AuthMessage copyWith({
  1. String? title,
  2. String? hint,
  3. String? reason,
})

Returns a copy of this AuthMessage with updated fields.

Example:

final newMessage = oldMessage.copyWith(title: "New Title");

Implementation

AuthMessage copyWith({String? title, String? hint, String? reason}) =>
    AuthMessage(
      title: title ?? this.title,
      hint: hint ?? this.hint,
      reason: reason ?? this.reason,
    );