public async Task DeleteImage(string itemId, string imageId)
        {
            var itemCacheFolder = GetItemCachePath(itemId);

            var imageFile = GetItemImagePath(itemCacheFolder, imageId);
            await _storageService.DeleteFileIfExists(imageFile);
        }
        public async Task MoveCompleted(BackgroundTransferRequest request)
        {
            var item             = JsonConvert.DeserializeObject <JobData>(request.Tag);
            var finalFile        = item.Location;
            var downloadLocation = string.Format(Constants.AnyTime.DownloadLocation, item.Id);

            await _storageService.MoveFileIfExists(downloadLocation, finalFile, true);

            await _storageService.DeleteFileIfExists(downloadLocation);

            BackgroundTransferService.Remove(request);

            _messengerService.SendSyncNotification(Constants.Messages.SyncJobFinishedMsg, item.Id, item.ItemType);
        }
Exemple #3
0
 public async Task DeleteFile(string path)
 {
     await _storageService.DeleteFileIfExists(path);
 }