copyWith method

AcceptOauthRequest copyWith({
  1. String? url,
  2. String? matchCode,
  3. bool? allowWriteAccess,
  4. bool? allowPhoneNumberAccess,
  5. TonConnectConnectData? tonConnectConnectData()?,
})

Returns a copy with the given fields replaced. For a nullable field pass a function, e.g. field: () => null to clear it.

Implementation

AcceptOauthRequest copyWith({
  String? url,
  String? matchCode,
  bool? allowWriteAccess,
  bool? allowPhoneNumberAccess,
  TonConnectConnectData? Function()? tonConnectConnectData,
}) => AcceptOauthRequest(
  url: url ?? this.url,
  matchCode: matchCode ?? this.matchCode,
  allowWriteAccess: allowWriteAccess ?? this.allowWriteAccess,
  allowPhoneNumberAccess:
      allowPhoneNumberAccess ?? this.allowPhoneNumberAccess,
  tonConnectConnectData: tonConnectConnectData != null
      ? tonConnectConnectData()
      : this.tonConnectConnectData,
);