diff options
author | Hakim El Hattab <hakim.elhattab@gmail.com> | 2017-02-08 12:56:51 +0100 |
---|---|---|
committer | Hakim El Hattab <hakim.elhattab@gmail.com> | 2017-02-08 12:56:51 +0100 |
commit | adc326139a51079c2b8908a13f5d6a474ca4ee9f (patch) | |
tree | 7bc8b0bce04a0691c9cd99a437330f4a45583feb | |
parent | 9f99ac8b849aa26df98232bfa04db50eb2baa5ee (diff) | |
download | fosdem-2018-presentation-adc326139a51079c2b8908a13f5d6a474ca4ee9f.tar fosdem-2018-presentation-adc326139a51079c2b8908a13f5d6a474ca4ee9f.tar.gz |
update deserialize regex to work with decimals
-rw-r--r-- | js/reveal.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/js/reveal.js b/js/reveal.js index 125a7b6..4502919 100644 --- a/js/reveal.js +++ b/js/reveal.js @@ -1230,7 +1230,7 @@ if( value === 'null' ) return null; else if( value === 'true' ) return true; else if( value === 'false' ) return false; - else if( value.match( /^\d+$/ ) ) return parseFloat( value ); + else if( value.match( /^[\d\.]+$/ ) ) return parseFloat( value ); } return value; |