Fixed fields export error

Fixed the javascript error thrown when exporting web app fields.
Removed some console.log and added some comments