Skip to content

Commit 8ee0fe8

Browse files
Type corrections after updating TypeScript definitions
1 parent 77c0a37 commit 8ee0fe8

4 files changed

Lines changed: 4 additions & 2 deletions

File tree

src/fs.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ interface JsonFile {
1818
path: string;
1919
data: unknown;
2020
indent: string;
21-
newline: string | null;
21+
newline: string | undefined;
2222
}
2323

2424
/**

src/get-new-version.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ function getNextVersion(oldVersion: string, bump: BumpRelease): string {
4646
// This is a special case when going from a non-prerelease version to a prerelease version.
4747
// SemVer sets the prerelease version to zero (e.g. "1.23.456" => "1.23.456-beta.0").
4848
// But the user probably expected it to be "1.23.456-beta.1" instead.
49+
// @ts-ignore
4950
newSemVer.prerelease[1] = "1";
5051
newSemVer.format();
5152
}

src/manifest.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export function isManifest(obj: any): obj is Manifest {
3434
/**
3535
* Determines whether the specified value is a string, null, or undefined.
3636
*/
37-
function isOptionalString(value: any): value is string | null | undefined {
37+
function isOptionalString(value: any): value is string | undefined {
3838
let type = typeof value;
3939
return value === null ||
4040
type === "undefined" ||

src/normalize-options.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// tslint:disable-next-line: match-default-export-name
12
import globby, { hasMagic } from "globby";
23
import { isReleaseType, ReleaseType } from "./release-type";
34
import { VersionBumpOptions } from "./types/version-bump-options";

0 commit comments

Comments
 (0)