@@ -169,7 +169,7 @@ public static async Task DecompressArchiveAsync(IShellPage associatedInstance)
169
169
170
170
public static async Task DecompressArchiveHereAsync ( IShellPage associatedInstance )
171
171
{
172
- if ( associatedInstance == null )
172
+ if ( associatedInstance ? . SlimContentPage == null )
173
173
return ;
174
174
175
175
foreach ( var selectedItem in associatedInstance . SlimContentPage . SelectedItems )
@@ -178,6 +178,9 @@ public static async Task DecompressArchiveHereAsync(IShellPage associatedInstanc
178
178
BaseStorageFile archive = await StorageHelpers . ToStorageItem < BaseStorageFile > ( selectedItem . ItemPath ) ;
179
179
BaseStorageFolder currentFolder = await StorageHelpers . ToStorageItem < BaseStorageFolder > ( associatedInstance . FilesystemViewModel . CurrentFolder . ItemPath ) ;
180
180
181
+ if ( archive is null )
182
+ return ;
183
+
181
184
if ( await FilesystemTasks . Wrap ( ( ) => IsArchiveEncrypted ( archive ) ) )
182
185
{
183
186
DecompressArchiveDialog decompressArchiveDialog = new ( ) ;
@@ -202,7 +205,7 @@ public static async Task DecompressArchiveHereAsync(IShellPage associatedInstanc
202
205
203
206
public static async Task DecompressArchiveToChildFolderAsync ( IShellPage associatedInstance )
204
207
{
205
- if ( associatedInstance == null )
208
+ if ( associatedInstance ? . SlimContentPage == null )
206
209
return ;
207
210
208
211
foreach ( var selectedItem in associatedInstance . SlimContentPage . SelectedItems )
@@ -213,6 +216,9 @@ public static async Task DecompressArchiveToChildFolderAsync(IShellPage associat
213
216
BaseStorageFolder currentFolder = await StorageHelpers . ToStorageItem < BaseStorageFolder > ( associatedInstance . FilesystemViewModel . CurrentFolder . ItemPath ) ;
214
217
BaseStorageFolder destinationFolder = null ;
215
218
219
+ if ( archive is null )
220
+ return ;
221
+
216
222
if ( await FilesystemTasks . Wrap ( ( ) => DecompressHelper . IsArchiveEncrypted ( archive ) ) )
217
223
{
218
224
DecompressArchiveDialog decompressArchiveDialog = new ( ) ;
0 commit comments