flutter-libphonenumber
flutter-libphonenumber copied to clipboard
MissingPluginException for normalizePhoneNumber()
Running the given sample program as-is. In the code, passing a valid phone number with iso code 'IN' to normalizePhoneNumber(). Clicking on "Show Details" button throws below exception:
Error: MissingPluginException(No implementation found for method normalizePhoneNumber on channel codeheadlabs.com/libphonenumber)
at Object.throw_ [as throw] (http://localhost:51447/dart_sdk.js:5037:11)
at MethodChannel._invokeMethod (http://localhost:51447/packages/flutter/src/services/system_channels.dart.lib.js:943:21)
at _invokeMethod.next (<anonymous>)
at http://localhost:51447/dart_sdk.js:37374:33
at _RootZone.runUnary (http://localhost:51447/dart_sdk.js:37245:59)
at _FutureListener.thenAwait.handleValue (http://localhost:51447/dart_sdk.js:32501:29)
at handleValueCallback (http://localhost:51447/dart_sdk.js:33028:49)
at Function._propagateToListeners (http://localhost:51447/dart_sdk.js:33066:17)
at _Future.new.[_completeWithValue] (http://localhost:51447/dart_sdk.js:32914:23)
at async._AsyncCallbackEntry.new.callback (http://localhost:51447/dart_sdk.js:32935:35)
at Object._microtaskLoop (http://localhost:51447/dart_sdk.js:37497:13)
at _startMicrotaskLoop (http://localhost:51447/dart_sdk.js:37503:13)
at http://localhost:51447/dart_sdk.js:33274:9
Same exception is thrown for other functions also- getRegionInfo(), getNameForNumber()
The only function that does not throw exception is isValidPhoneNumber(), but this returns false always, another issue is already open for the same.