got it working! wasn't my fault. it was cordova. adding some logging.