Skip to content

Commit

Permalink
fix: specify result type for Result.fromJSON
Browse files Browse the repository at this point in the history
  • Loading branch information
nobrayner committed Sep 1, 2024
1 parent 7782abb commit ac7c834
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/OptionResult.ts
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ class __Result<A, E> {
return false;
};

static fromJSON = <A, E>(value: JsonResult<A, E>) => {
static fromJSON = <A, E>(value: JsonResult<A, E>): Result<A, E> => {
return value.tag === "Ok"
? Result.Ok(value.value)
: Result.Error(value.error);
Expand Down

0 comments on commit ac7c834

Please sign in to comment.