Fix toast message when sending a message
This commit is contained in:
@@ -3,9 +3,12 @@ import 'package:model/model.dart';
|
||||
extension ListAttachmentExtension on List<Attachment> {
|
||||
|
||||
num totalSize() {
|
||||
final currentListSize = map((attachment) => attachment.size?.value ?? 0).toList();
|
||||
final totalSize = currentListSize.reduce((sum, size) => sum + size);
|
||||
return totalSize;
|
||||
if (isNotEmpty) {
|
||||
final currentListSize = map((attachment) => attachment.size?.value ?? 0).toList();
|
||||
final totalSize = currentListSize.reduce((sum, size) => sum + size);
|
||||
return totalSize;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
List<Attachment> get listAttachmentsDisplayedOutSide {
|
||||
|
||||
Reference in New Issue
Block a user