Although it's rare, you can end up with a NaN in your state if it's the output of a mathematical function.
NaN is tricky:
NaN === NaN; // falseNumber.NaN === NaN; // falseNumber.isNaN(NaN); // true
This PR prevents the middleware from throwing if there is a NaN in the state
Coverage remained the same at 100.0% when pulling b21595635a88d3c4e8223f2bb7203c140415fb72 on matthieu-foucault:NaN_handling into 3a2c64750f5e64ddf748d82fa93ff29aa88b8a8f on leoasis:master.
Coverage remained the same at 100.0% when pulling dd32c346f3fcfbbed31918da2c0359afb2451358 on matthieu-foucault:NaN_handling into 3a2c64750f5e64ddf748d82fa93ff29aa88b8a8f on leoasis:master.
Although it's rare, you can end up with a NaN in your state if it's the output of a mathematical function. NaN is tricky:
NaN === NaN; // false
Number.NaN === NaN; // false
Number.isNaN(NaN); // true
This PR prevents the middleware from throwing if there is a NaN in the state