Finally, I find a solution to this problem! during the first update, run the following commands:
npm i @ionic/ app-scripts@latest --save npm i ionic-native@latest --save
And probably somewhere in your code you are calling something related to the file transfer plugin before
platform.ready.then()
In my case: I am adding some service that includes a line like this:
this.fileTransfer = this.transfer.create();
And I changed it to this:
this.platform.ready().then(() => { // Okay, so the platform is ready and our plugins are available. // Here you can do any higher level native things you might need. this.fileTransfer = this.transfer.create(); });
Now everything is working fine.
More details:
Why does this work in debug mode?
The answer is very clear, because in debug mode, the device is ready for an event, it gives a long time for a fire and transfer of files caused after that absolutely! But in production mode, the device is ready to launch very quickly, and file transfer is called before. Hope this helps you.
source share