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

ASF GitHub Bot commented on CB-8521:
------------------------------------

Github user vladimir-kotikov commented on a diff in the pull request:

    https://github.com/apache/cordova-lib/pull/178#discussion_r26284609
  
    --- Diff: cordova-lib/src/plugman/fetch.js ---
    @@ -144,7 +144,10 @@ function fetchPlugin(plugin_src, plugins_dir, options) 
{
             });
         }).then(function(result){
             checkID(options.expected_id, result.pinfo);
    -        metadata.save_fetch_metadata(plugins_dir, result.pinfo.id, { 
source: result.fetchJsonSource });
    +        var data = { source: result.fetchJsonSource };
    +        data.is_top_level = options.is_top_level; 
    --- End diff --
    
    IMHO it's better to use an object literal here instead of assigning 
properties.
    
    ```javascript
    var data = {
        source: result.fetchJsonSource,
        is_top_level: options.is_top_level,
        variables: options.variables || {}
    };
    ```


> 'cordova plugin save' should save all installed plugins and their 
> version/git-url/folder-location into config.xml
> -----------------------------------------------------------------------------------------------------------------
>
>                 Key: CB-8521
>                 URL: https://issues.apache.org/jira/browse/CB-8521
>             Project: Apache Cordova
>          Issue Type: New Feature
>            Reporter: Omar Mefire
>            Assignee: Omar Mefire
>
> In addition to using 'cordova plugin add org.apache.cordova.device --save' to 
> both add and save a plugin to config.xml, It would be useful to have a way to 
> 'mass save' already installed plugins to config.xml.



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

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

Reply via email to