API/api.medcify.app/node_modules/validator/es/lib/toFloat.js

5 lines
132 B
JavaScript
Raw Normal View History

2022-09-26 06:11:44 +00:00
import isFloat from './isFloat';
export default function toFloat(str) {
if (!isFloat(str)) return NaN;
return parseFloat(str);
}