becvert / cordova-plugin-zeroconf

Cordova ZeroConf Plugin
MIT License
81 stars 57 forks source link

Proposal: expose a reInit() action #50

Closed emcniece closed 6 years ago

emcniece commented 6 years ago

Adds a reInit action that wipes the previously instantiated contexts and restarts the plugin as if it were a fresh app boot.

If the Wifi network changes while the app is running, scan results do not update and errors are thrown for calls like close(). This can be avoided by reinstantiating the class, particularly for Android.

Resolves https://github.com/becvert/cordova-plugin-zeroconf/issues/51