incubator-callback-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Becky Gibson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CB-1566) SetMetaData on folder not working
Date Thu, 04 Oct 2012 16:59:47 GMT

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

Becky Gibson commented on CB-1566:
----------------------------------

The problem is the creation of the object that is passed in the options parameter. With the
code in the example the key is actually set as "metadataKey" and not the value of the variable
by that name.  See http://docs.phonegap.com/en/2.1.0/cordova_file_file.md.html#DirectoryEntry_setmetadata

this corrects it: 
var onGetDirectoryWin = function(parent) {
                    var dataObj = {};
                    dataObj[metadataKey] = metadataValue;
                    parent.setMetadata(onSetMetadataWin, onSetMetadataFail, dataObj);
                }


                
> SetMetaData on folder not working
> ---------------------------------
>
>                 Key: CB-1566
>                 URL: https://issues.apache.org/jira/browse/CB-1566
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: iOS
>    Affects Versions: 2.1.0
>            Reporter: Peter Warren
>            Assignee: Shazron Abdullah
>
> Copied code from 2.1 docs (setFolderMetadata)
> http://docs.phonegap.com/en/2.1.0/cordova_file_file.md.html#Metadata
> console output "error setting metadata Error"
> Line 538 of CDVFile.m fails to retrieve attribute value even though the correct value
was passed in to the (js)function call.
> NSDictionary* options= [command.arguments objectAtIndex:1 withDefault:nil]

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message