toDoubleOrNull

Returns content as Double only if it can be an exact Double or inf/+inf/-inf/nan, otherwise null.