-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(allow-list)!: integrate and refactor core plugin #1138
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code LGTM 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks okay to me
boolean external = (xml.getAttributeValue(null, "launch-external") != null); | ||
if (origin != null) { | ||
if (external) { | ||
LOG.w(LOG_TAG, "Found <access launch-external> within config.xml. Please use <allow-intent> instead."); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now seems like a good time to drop this deprecated <access launch-external>
support?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, we can remove this now too... I didn't carefully read to notice that this deprecated code existed. I will go ahead and delete this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dpogue The launch-external
has been removed: 4fc48ff?diff=split&w=1
I also moved the String subdomains
into the else statement where it is used.
Codecov Report
@@ Coverage Diff @@
## master #1138 +/- ##
=======================================
Coverage 71.19% 71.19%
=======================================
Files 21 21
Lines 1739 1739
=======================================
Hits 1238 1238
Misses 501 501 Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Whitelist
class rename to AllowList
sounds like a breaking change to me, which means this should be targeted for cordova-android@10, correct?
Yes, because the core's original classname was renamed, this is a major change. |
Should we resolve the conflicts and move forward with this? Especially as we should solve #1217 after merging this PR. |
Codecov Report
@@ Coverage Diff @@
## master #1138 +/- ##
=======================================
Coverage 71.90% 71.90%
=======================================
Files 21 21
Lines 1694 1694
=======================================
Hits 1218 1218
Misses 476 476 Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome effort. Great.
This comment was marked as off-topic.
This comment was marked as off-topic.
@dalyboub Please go to Stack Overflow or Slack for questions. Issues and pullrequests are not for questions. |
Congratulations, you've broken my code. Granted, using the word ‘whitelist’ might make some people feel bad. But what about all the developer hours wasted by having to deal with a breaking change? Does this not factor into your ethics? |
Apache uses a Code of Conduct to guide decisions such as these. More importantly we had community users raise the issue and other community members volunteer their time to solve their complaints. We also strive not to include breaking changes. However, sometimes it is necessary. We reserve breaking changes to major version updates, so that by default, breaking changes aren't automatically rolled into your projects. As with any library or framework using the semver version model, it would be expected that major version upgrades requires some foresight and may require refactoring on our users end. Breaking changes are generally listed in our changelog. If you want to discuss Cordova's strategies for releases or provide advice on how we can improve the release process that can be done via our Mailing List. A closed PR is not the place for that kind of discussion. For that reason I'm locking this thread. |
Motivation, Context & Description
Integrate the Allow List core plugin to platform.
Testing
npm t
cordova create
cordova platform add
cordova build android
Run in emulator though Android Studio.
Checklist