cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bhigg...@apache.org
Subject [1/4] git commit: CB-7167 [BlackBerry10] copyTo - return wrapped entry rather than native
Date Mon, 21 Jul 2014 19:50:22 GMT
Repository: cordova-plugin-file
Updated Branches:
  refs/heads/master 913b9a3cc -> 56976ae25


CB-7167 [BlackBerry10] copyTo - return wrapped entry rather than native


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/commit/56976ae2
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/tree/56976ae2
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/diff/56976ae2

Branch: refs/heads/master
Commit: 56976ae252f01e05b6c7301c5192b0285e29a143
Parents: 6b09950
Author: Bryan Higgins <bhiggins@blackberry.com>
Authored: Fri Jul 18 13:01:25 2014 -0400
Committer: Bryan Higgins <bhiggins@blackberry.com>
Committed: Fri Jul 18 14:16:45 2014 -0400

----------------------------------------------------------------------
 www/blackberry10/copyTo.js | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-file/blob/56976ae2/www/blackberry10/copyTo.js
----------------------------------------------------------------------
diff --git a/www/blackberry10/copyTo.js b/www/blackberry10/copyTo.js
index ebbce41..36bc8c6 100644
--- a/www/blackberry10/copyTo.js
+++ b/www/blackberry10/copyTo.js
@@ -42,9 +42,15 @@ module.exports = function (success, fail, args, move) {
         fileName = args[2],
         copiedEntry,
         onSuccess = function () {
-            if (typeof(success) === 'function') {
-                success(copiedEntry);
-            }
+            resolve(
+                function (entry) {
+                    if (typeof(success) === 'function') {
+                        success(entry);
+                    }
+                },
+                onFail,
+                [destination + copiedEntry.name]
+            );
         },
         onFail = function (error) {
             if (typeof(fail) === 'function') {


Mime
View raw message