Skip to content

Commit

Permalink
Merge pull request #669
Browse files Browse the repository at this point in the history
Typescript definitions: added null to return types of functions that may return null
  • Loading branch information
Stuk committed May 31, 2020
2 parents 2569772 + 5abc6cf commit 87fa545
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.d.ts
Expand Up @@ -154,7 +154,7 @@ interface JSZip {
* @param Path relative path to file
* @return File matching path, null if no file found
*/
file(path: string): JSZip.JSZipObject;
file(path: string): JSZip.JSZipObject | null;

/**
* Get files matching a RegExp from archive
Expand All @@ -181,7 +181,7 @@ interface JSZip {
* @param name Name of the folder
* @return New JSZip object with the given folder as root or null
*/
folder(name: string): JSZip;
folder(name: string): JSZip | null;

/**
* Returns new JSZip instances with the matching folders as root
Expand Down

0 comments on commit 87fa545

Please sign in to comment.