Closed smelzer closed 5 years ago
@smelzer yes... please go ahead and create the PR. I'm currently working in a complete refactor for the plugin. I will make sure to merge your PR and get the changes into the new version.
Roman, I created a PR with both iOS and Android support for HTTP headers. As I stated in the long comments, I tested with small test harnesses in Xcode and Android Studio but I do not know how to actually test with Cordova. I would need some help with that. I did test with the harnesses quite extensively though and it seems to be fully backward-compatible and non-breaking.
I tried to keep the code changes very small. In the case of iOS I used a iOS 9.0 deprecated function (sendSynchronousRequest) to keep from needing blocks and changing the structure of the existing code. But the existing code uses the UIAlertView which is also iOS 9.0 deprecated, so I figured if you ever want to fix the one we can fix the other. It'll be a long time before Apple gets rid of either function or class.
This is the first time I have done a fork and a PR in GitHub, so if I did anything wrong please let me know. I did not edit the readme file but I did put in an example in the PR comment. I would be happy to change the readme file.
Steve
Sarriaroman, I want to add HTTP header support to this plugin so that it will support secure URLs. I am happy to make the changes in both iOS and Android, but before I go down this road, I want to make sure you are still supporting this project.