sahlhoff / react-native-pulse

React Native Pulse Animation
MIT License
149 stars 49 forks source link

Need to clear Intervals on Unmount #2

Closed joncursi closed 8 years ago

joncursi commented 8 years ago

This component creates a few setIntervals. They need to be cleared when the component is unmounted. Otherwise, the intervals will continue to run but the component does not exist so the console will throw errors:

ExceptionsManager.js:78 Warning: setState(...): Can only update a mounted or mounting component. This usually means you called setState() on an unmounted component. This is a no-op. Please check the code for the Pulse component.
sahlhoff commented 8 years ago

Thanks again. Just pushed a fix.

joncursi commented 8 years ago

👍