mkuczera / react-native-haptic-feedback

React-Native Haptic Feedback for iOS with Android similar behaviour.
MIT License
872 stars 106 forks source link

Fix for iPhone X and future iPhones #12

Closed MattFoley closed 6 years ago

MattFoley commented 6 years ago

The check for iPhone X was returning 0 from device version, since it's actually iPhone10,. This updates that function to take the substring before the comma, and then remove all non-digit characters, rather than just taking the first character.

MattFoley commented 6 years ago

@mkuczera That was fast, thanks!

mkuczera commented 6 years ago

Thanks for the PR ;)