React-native-fs: error in android: RNFSManager tried to override RNFSManager

Created on 8 Nov 2016  路  2Comments  路  Source: itinance/react-native-fs

In android I get this at startup:

java.lang.IllegalStateException: Native module RNFSManager tried to override RNFSManager for module name RNFSManager. If this was your intention, return true from RNFSManager#canOverrideExistingModule()

ver. 1.5.1 and 2.0.1-rc2

Any idea? It works just fine in IOS.
Thanks.

Most helpful comment

found the issue. RNFS was imported twice in android. probably a glitch from link. now it's ok.

All 2 comments

found the issue. RNFS was imported twice in android. probably a glitch from link. now it's ok.

Ah! I just learn something. Whenever react-native link <package-name> is used it automatically insert the various import and @override ... new <package>() in MainApplication.java.

Good to know.

Was this page helpful?
0 / 5 - 0 ratings