diff --git a/package.json b/package.json index 391685e..cfebc13 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-currency-input", - "version": "1.2.1", + "version": "1.2.2", "description": "React component for inputing currency amounts", "main": "lib/index.js", "scripts": { diff --git a/src/index.js b/src/index.js index 209b36a..e2d8428 100644 --- a/src/index.js +++ b/src/index.js @@ -49,7 +49,7 @@ const CurrencyInput = React.createClass({ * @returns {{ maskedValue: {String}, value: {Number}, customProps: {Object} }} */ prepareProps(props) { - let customProps = Object.assign({}, props); //polyfilled for environments that do not support it. + let customProps = JSON.parse(JSON.stringify(props)); //not as clean, but better support delete customProps.onChange; delete customProps.value; delete customProps.decimalSeparator;