File tree 2 files changed +5
-2
lines changed
2 files changed +5
-2
lines changed Original file line number Diff line number Diff line change 19
19
20
20
using System . Collections . Generic ;
21
21
22
+ #nullable enable
23
+
22
24
namespace OpenQA . Selenium
23
25
{
24
26
/// <summary>
Original file line number Diff line number Diff line change @@ -530,15 +530,16 @@ public IReadOnlyList<string> GetDownloadableFiles()
530
530
throw new WebDriverException ( "GetDownloadableFiles returned successfully, but response content was not an object: " + commandResponse . Value ) ;
531
531
}
532
532
533
- object [ ] namesArray = ( object [ ] ) value [ "names" ] ! ;
534
- return namesArray . Select ( obj => obj . ToString ( ) ! ) . ToList ( ) ;
533
+ object ? [ ] namesArray = ( object ? [ ] ) value [ "names" ] ! ;
534
+ return namesArray . Select ( obj => obj ! . ToString ( ) ! ) . ToList ( ) ;
535
535
}
536
536
537
537
/// <summary>
538
538
/// Downloads a file with the specified file name.
539
539
/// </summary>
540
540
/// <param name="fileName">The name of the file to be downloaded.</param>
541
541
/// <param name="targetDirectory">The target directory where the file should be downloaded to.</param>
542
+ /// <exception cref="ArgumentNullException">If <paramref name="targetDirectory"/> is null.</exception>
542
543
public void DownloadFile ( string fileName , string targetDirectory )
543
544
{
544
545
var enableDownloads = this . Capabilities . GetCapability ( CapabilityType . EnableDownloads ) ;
You can’t perform that action at this time.
0 commit comments