ScheduledFileMessageParams.withUrl constructor Null safety

ScheduledFileMessageParams.withUrl(
  1. String fileUrl,
  2. {String? fileType,
  3. int? size,
  4. String? name,
  5. String? data,
  6. required int scheduledAt,
  7. String? customType,
  8. bool requiredAuth = true,
  9. bool sendPush = true,
  10. bool isSilent = false,
  11. bool markAsRead = true,
  12. List<MessageMetaArray>? metaArrays,
  13. String? apnsBundleId,
  14. AppleCriticalAlertOptions? appleCriticalAlertOptions,
  15. PushNotificationDeliveryOption pushOption = PushNotificationDeliveryOption.normal,
  16. MentionType mentionType = MentionType.users}
)

Implementation

ScheduledFileMessageParams.withUrl(
  String fileUrl, {
  this.fileType,
  this.size,
  this.name,
  this.data,
  required this.scheduledAt,
  this.customType,
  this.requiredAuth = true,
  this.sendPush = true,
  this.isSilent = false,
  this.markAsRead = true,
  this.metaArrays,
  this.apnsBundleId,
  this.appleCriticalAlertOptions,
  this.pushOption = PushNotificationDeliveryOption.normal,
  this.mentionType = MentionType.users,
}) : uploadFile = FileInfo.fromUrl(
        name: name ?? 'image',
        mimeType: fileType ?? 'image/jpeg',
        url: fileUrl,
        fileSize: size,
      );