applejacko / cordova-plugin-uic-udp

A Cordova plugin for UDP communications, currently one-way: send only.
15 stars 18 forks source link

udptransmit.js reduntant header #4

Open davideberra opened 9 years ago

davideberra commented 9 years ago

Hi! I got a problem compiling udp transmit plugin with cordova 3.6.0.

It looks like the header of udptransmit.js

cordova.define("edu.uic.travelmidwest.cordova.udptransmit.udptransmit", function(require, exports, module) .....

will be nested into another identical header by cordova build process.

Result:

cordova.define("edu.uic.travelmidwest.cordova.udptransmit.udptransmit", function(require, exports, module) { cordova.define("edu.uic.travelmidwest.cordova.udptransmit.udptransmit", function(require, exports, module) { var exec = require('cordova/exec'); var platform = require('cordova/platform'); .....

Solution: remove the above header from udptransmit.js. Cordova will put it automatically for us.

mattchete commented 9 years ago

I just ran into this error and didn't find where it came from. Your solution is working, thanks !

applejacko commented 9 years ago

Sorry guys.

Yeah, that's why I have (and had) the:

// Start of cut and paste area (to put back in Git repo version of this file) and // End of cut and paste area

comments for myself, to mark the section of code I need to put back in the repo after I make the changes in my project.

I changed it. Let me know if it's OK for you.

Jack

mattchete commented 9 years ago

It's ok for me, thanks.

applejacko commented 9 years ago

Good! Thanks for confirming.