You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by kn...@apache.org on 2019/03/11 02:54:30 UTC

[cordova-plugin-file] branch travis_tests updated: err log is added for debug

This is an automated email from the ASF dual-hosted git repository.

knaito pushed a commit to branch travis_tests
in repository https://gitbox.apache.org/repos/asf/cordova-plugin-file.git


The following commit(s) were added to refs/heads/travis_tests by this push:
     new a72b139  err log is added for debug
a72b139 is described below

commit a72b139f8ad5605aa85e903593291af05cd17939
Author: knaito <kn...@asial.co.jp>
AuthorDate: Mon Mar 11 11:54:14 2019 +0900

    err log is added for debug
---
 src/browser/FileProxy.js | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/src/browser/FileProxy.js b/src/browser/FileProxy.js
index 1096a15..26d9d65 100644
--- a/src/browser/FileProxy.js
+++ b/src/browser/FileProxy.js
@@ -100,11 +100,7 @@
 
             var root = new DirectoryEntry('', DIR_SEPARATOR);
             fs_ = new FileSystem(name, root);
-            
-            window.customLog('log', 'protocol = ' + location.protocol);
-            window.customLog('log', 'host = ' + location.host);
-            window.customLog('log', 'storageName = ' + storageName);
-            window.customLog('log', 'requestFileSystem step 2 ');
+
             idb_.open(storageName, function () {
                 // window.customLog('log', '***** ' + successCallback.toString());
                 successCallback(fs_);
@@ -184,8 +180,8 @@
                                 lastModifiedDate: new Date(),
                                 storagePath: path.storagePath
                             });
-
                             idb_.put(newFileEntry, path.storagePath, successCallback, errorCallback);
+
                         }, errorCallback);
                     } else {
                         if (errorCallback) {
@@ -887,7 +883,10 @@
 
             var request = tx.objectStore(FILE_STORE_).get(fullPath);
 
-            tx.onabort = errorCallback || onError;
+            tx.onabort = function (err) {
+                window.customLog('log', err.toString());
+                (errorCallback || onError)(err);
+            };
             tx.oncomplete = function () {
                 successCallback(request.result);
             };


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