faizalshap / react-native-otp-verify

React native sms verification without additional permissions
MIT License
241 stars 95 forks source link

TypeError: null is not an object (evaluating '/(\d{8})/g.exec(t)[1]') #38

Closed DBzera closed 3 years ago

DBzera commented 3 years ago

After open the app and start listening to the otp, after a while it breaks into this error message: Image from iOS Any known solution?

DBzera commented 3 years ago

Just add a if (message) inside the listener function, and put the regex inside it.