Skip to content

Commit

Permalink
[ISSUE-6268] returns NaN insteadof nan (#7498)
Browse files Browse the repository at this point in the history
* returns NaN insteadof nan

* clang-format-git
  • Loading branch information
3axap4eHko committed Aug 31, 2022
1 parent 37e37b8 commit 5634dc3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/idl_gen_ts.cpp
Expand Up @@ -439,7 +439,9 @@ class TsGenerator : public BaseGenerator {
return "BigInt('" + value.constant + "')";
}

default: return value.constant;
default:
if (value.constant == "nan") { return "NaN"; }
return value.constant;
}
}

Expand Down

0 comments on commit 5634dc3

Please sign in to comment.