From 7201c9b96511bcb5ec23e3d14c53357158b70b0d Mon Sep 17 00:00:00 2001 From: oganexon Date: Fri, 30 Aug 2019 14:40:38 +0200 Subject: [PATCH] refix --- CHANGELOG.md | 5 +++++ package-lock.json | 2 +- package.json | 2 +- src/secure-rm.ts | 1 + 4 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bfc4bd8..80a2361 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [3.0.3] - 2019-08-30 + +### Fixed +- Default standard when none is provided. (Tests are now a priority) + ## [3.0.2] - 2019-08-30 ### Fixed diff --git a/package-lock.json b/package-lock.json index f02d42d..c60fba0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "secure-rm", - "version": "3.0.2", + "version": "3.0.3", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 4dee823..11c27ee 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "secure-rm", - "version": "3.0.2", + "version": "3.0.3", "description": "Completely erases files by making recovery impossible.", "main": "./dist/index.js", "types": "./dist/index.d.ts", diff --git a/src/secure-rm.ts b/src/secure-rm.ts index 8ec01f8..7563699 100644 --- a/src/secure-rm.ts +++ b/src/secure-rm.ts @@ -31,6 +31,7 @@ export function unlink(path: string, options?: Options | Callback, callback?: Ca options = { standard: 'secure' } } // Define standard if none is provided + if (options === undefined) options = { standard: 'secure' } if ((options as Options).standard === undefined) (options as Options).standard = 'secure' if (callback) unlinkCallback(path, options as ParsedOptions, (err: NodeJS.ErrnoException | null, path: string) => callback!(err, path))