You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "Tony Homer (JIRA)" <ji...@apache.org> on 2015/06/09 17:26:00 UTC

[jira] [Commented] (CB-9145) prepare can lose data during config munge

    [ https://issues.apache.org/jira/browse/CB-9145?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14579072#comment-14579072 ] 

Tony Homer commented on CB-9145:
--------------------------------

It looks like the logic for detecting exact matches was added here:
https://github.com/apache/cordova-lib/commit/9b5f464a4852c4bd17e045613be853a7c72808ff#diff-c62b47d2900f2d5dc6335bf1b6def0c2R111

I have a preliminary fix for this; I do a 2-way comparison instead of the existing one way comparison.

Tests were added at same time as the "exact match logic", so I should be able to adapt one of them to test for this case.
Looking into that now.

> prepare can lose data during config munge
> -----------------------------------------
>
>                 Key: CB-9145
>                 URL: https://issues.apache.org/jira/browse/CB-9145
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: CordovaLib
>    Affects Versions: Master
>            Reporter: Tony Homer
>
> If a node is added to config.xml with same name and matching attributes as an existing node, but it is missing attributes, it is treated as an exact match during config munge and is not added to platform config.xml.  For example, when the following tags are present in www/config.xml, then second tag will not be added to platforms/android/res/xml/config.xml:
> {code}
> <access origin="*" launch-external="yes"/>
> <access origin="*" />
> {code}
> AFAIK, this is most important for access tags, but will affect any tag where it is possible for one tag to be a subset of another tag.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org