fix #354
Some checks are pending
Flutter analyze & test / flutter_analyze_and_test (push) Waiting to run

This commit is contained in:
otsmr 2025-12-26 22:43:24 +01:00
parent 6dc9aa10bc
commit b093a7acdb
3 changed files with 5 additions and 3 deletions

View file

@ -219,7 +219,7 @@ class MediaFileService {
await tempPath.copy(storedPath.path); await tempPath.copy(storedPath.path);
} else { } else {
Log.error( Log.error(
'Could not store image neither as tempPath does not exists.', 'Could not store image neither as ${tempPath.path} does not exists.',
); );
} }
unawaited(createThumbnail()); unawaited(createThumbnail());

View file

@ -474,7 +474,9 @@ class _ShareImageEditorView extends State<ShareImageEditorView> {
mediaService.tempPath.deleteSync(); mediaService.tempPath.deleteSync();
} }
if (mediaService.originalPath.existsSync()) { if (mediaService.originalPath.existsSync()) {
mediaService.originalPath.deleteSync(); if (media.type != MediaType.video) {
mediaService.originalPath.deleteSync();
}
} }
var bytes = imageBytes; var bytes = imageBytes;
if (media.type == MediaType.gif) { if (media.type == MediaType.gif) {

View file

@ -133,7 +133,7 @@ class _MemoriesPhotoSliderViewState extends State<MemoriesPhotoSliderView> {
} }
orgMediaService.storedPath orgMediaService.storedPath
.copySync(newMediaService.tempPath.path); .copySync(newMediaService.originalPath.path);
if (!context.mounted) return; if (!context.mounted) return;