Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
luckyrat committed Aug 31, 2023
1 parent 979eac0 commit e0a7bba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/widgets/binaries.dart
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,7 @@ class BinaryCardWidget extends StatelessWidget {
builder: (BuildContext context) {
return TextButton.icon(
onPressed: () async {
final box = context.findRenderObject() as RenderBox?;
WidgetsBinding.instance.addPostFrameCallback((_) async {
final attachmentSource = AttachmentSourceKdbx();
final bytes = await attachmentSource.readAttachmentBytes(attachment.value);
Expand All @@ -236,7 +237,6 @@ class BinaryCardWidget extends StatelessWidget {
await file.writeAsBytes(bytes, flush: true);
try {
final xFile = XFile(file.path, mimeType: mimeType);
final box = context.findRenderObject() as RenderBox?;
await Share.shareXFiles(
[xFile],
subject: 'Kee Vault attachment',
Expand Down

0 comments on commit e0a7bba

Please sign in to comment.