Skip to content

Commit

Permalink
backport NAb fix (#4842)
Browse files Browse the repository at this point in the history
  • Loading branch information
labkey-willm authored Oct 20, 2023
1 parent 372298d commit 2bf6909
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion api/src/org/labkey/api/util/JsonUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ public static void safePut(JSONObject json, String key, Number value)
json.put(key, translateNumber(value));
}

private static Object translateNumber(Number value)
public static Object translateNumber(Number value)
{
if (value instanceof Double d)
{
Expand Down
2 changes: 1 addition & 1 deletion core/src/org/labkey/core/statistics/ParameterCurveFit.java
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ protected SigmoidalParameters calculateFitParameters(double minValue, double max
{
double absoluteCutoff = min + (0.5 * (max - min));
double relativeEC50 = getInterpolatedCutoffXValue(absoluteCutoff);
if (relativeEC50 != Double.POSITIVE_INFINITY && relativeEC50 != Double.NEGATIVE_INFINITY)
if (!Double.isInfinite(relativeEC50) && !Double.isNaN(relativeEC50))
{
parameters.max = max;
parameters.inflection = relativeEC50;
Expand Down

0 comments on commit 2bf6909

Please sign in to comment.