@@ -354,7 +354,7 @@ public void DeleteDirectory(string path)
354
354
355
355
if ( string . IsNullOrWhiteSpace ( path ) )
356
356
{
357
- throw new ArgumentException ( " path" ) ;
357
+ throw new ArgumentException ( nameof ( path ) ) ;
358
358
}
359
359
360
360
if ( _sftpSession is null )
@@ -383,7 +383,7 @@ public void DeleteFile(string path)
383
383
384
384
if ( string . IsNullOrWhiteSpace ( path ) )
385
385
{
386
- throw new ArgumentException ( " path" ) ;
386
+ throw new ArgumentException ( nameof ( path ) ) ;
387
387
}
388
388
389
389
if ( _sftpSession is null )
@@ -414,7 +414,7 @@ public async Task DeleteFileAsync(string path, CancellationToken cancellationTok
414
414
415
415
if ( string . IsNullOrWhiteSpace ( path ) )
416
416
{
417
- throw new ArgumentException ( " path" ) ;
417
+ throw new ArgumentException ( nameof ( path ) ) ;
418
418
}
419
419
420
420
if ( _sftpSession is null )
@@ -541,12 +541,12 @@ public void SymbolicLink(string path, string linkPath)
541
541
542
542
if ( string . IsNullOrWhiteSpace ( path ) )
543
543
{
544
- throw new ArgumentException ( " path" ) ;
544
+ throw new ArgumentException ( nameof ( path ) ) ;
545
545
}
546
546
547
547
if ( string . IsNullOrWhiteSpace ( linkPath ) )
548
548
{
549
- throw new ArgumentException ( " linkPath" ) ;
549
+ throw new ArgumentException ( nameof ( linkPath ) ) ;
550
550
}
551
551
552
552
if ( _sftpSession is null )
@@ -743,7 +743,7 @@ public bool Exists(string path)
743
743
744
744
if ( string . IsNullOrWhiteSpace ( path ) )
745
745
{
746
- throw new ArgumentException ( " path" ) ;
746
+ throw new ArgumentException ( nameof ( path ) ) ;
747
747
}
748
748
749
749
if ( _sftpSession is null )
@@ -874,7 +874,7 @@ public IAsyncResult BeginDownloadFile(string path, Stream output, AsyncCallback?
874
874
875
875
if ( string . IsNullOrWhiteSpace ( path ) )
876
876
{
877
- throw new ArgumentException ( " path" ) ;
877
+ throw new ArgumentException ( nameof ( path ) ) ;
878
878
}
879
879
880
880
if ( output is null )
@@ -1096,7 +1096,7 @@ public IAsyncResult BeginUploadFile(Stream input, string path, bool canOverride,
1096
1096
1097
1097
if ( string . IsNullOrWhiteSpace ( path ) )
1098
1098
{
1099
- throw new ArgumentException ( " path" ) ;
1099
+ throw new ArgumentException ( nameof ( path ) ) ;
1100
1100
}
1101
1101
1102
1102
var flags = Flags . Write | Flags . Truncate ;
@@ -2091,7 +2091,7 @@ public IEnumerable<FileInfo> SynchronizeDirectories(string sourcePath, string de
2091
2091
2092
2092
if ( string . IsNullOrWhiteSpace ( destinationPath ) )
2093
2093
{
2094
- throw new ArgumentException ( " destinationPath" ) ;
2094
+ throw new ArgumentException ( nameof ( destinationPath ) ) ;
2095
2095
}
2096
2096
2097
2097
return InternalSynchronizeDirectories ( sourcePath , destinationPath , searchPattern , asynchResult : null ) ;
@@ -2120,7 +2120,7 @@ public IAsyncResult BeginSynchronizeDirectories(string sourcePath, string destin
2120
2120
2121
2121
if ( string . IsNullOrWhiteSpace ( destinationPath ) )
2122
2122
{
2123
- throw new ArgumentException ( "destDir" ) ;
2123
+ throw new ArgumentException ( nameof ( destinationPath ) ) ;
2124
2124
}
2125
2125
2126
2126
if ( searchPattern is null )
@@ -2338,7 +2338,7 @@ private void InternalDownloadFile(string path, Stream output, SftpDownloadAsyncR
2338
2338
2339
2339
if ( string . IsNullOrWhiteSpace ( path ) )
2340
2340
{
2341
- throw new ArgumentException ( " path" ) ;
2341
+ throw new ArgumentException ( nameof ( path ) ) ;
2342
2342
}
2343
2343
2344
2344
if ( _sftpSession is null )
@@ -2404,7 +2404,7 @@ private void InternalUploadFile(Stream input, string path, Flags flags, SftpUplo
2404
2404
2405
2405
if ( string . IsNullOrWhiteSpace ( path ) )
2406
2406
{
2407
- throw new ArgumentException ( " path" ) ;
2407
+ throw new ArgumentException ( nameof ( path ) ) ;
2408
2408
}
2409
2409
2410
2410
if ( _sftpSession is null )
0 commit comments