cordova-file-cache
Advanced tools
Comparing version 0.4.1 to 0.5.0
{ | ||
"name": "cordova-file-cache", | ||
"main": "dist/CordovaFileCache.js", | ||
"version": "0.4.1", | ||
"version": "0.5.0", | ||
"homepage": "https://github.com/markmarijnissen/cordova-file-cache", | ||
@@ -6,0 +6,0 @@ "authors": [ |
@@ -259,3 +259,3 @@ var CordovaFileCache = | ||
if(this._cached[path]) return this._cached[path].toInternalURL; | ||
return this._fs.toInternalURLSync(path); | ||
return this.toServerURL(path); | ||
}; | ||
@@ -269,5 +269,5 @@ | ||
FileCache.prototype.toURL = function toInternalURL(url){ | ||
FileCache.prototype.toURL = function toURL(url){ | ||
path = this.toPath(url); | ||
return this._cached[path]? this._cached[path].toURL: url; | ||
return this._cached[path]? this._cached[path].toURL: this.toServerURL(url); | ||
}; | ||
@@ -274,0 +274,0 @@ |
@@ -212,3 +212,3 @@ var hash = require('./murmerhash'); | ||
if(this._cached[path]) return this._cached[path].toInternalURL; | ||
return this._fs.toInternalURLSync(path); | ||
return this.toServerURL(path); | ||
}; | ||
@@ -222,5 +222,5 @@ | ||
FileCache.prototype.toURL = function toInternalURL(url){ | ||
FileCache.prototype.toURL = function toURL(url){ | ||
path = this.toPath(url); | ||
return this._cached[path]? this._cached[path].toURL: url; | ||
return this._cached[path]? this._cached[path].toURL: this.toServerURL(url); | ||
}; | ||
@@ -227,0 +227,0 @@ |
{ | ||
"name": "cordova-file-cache", | ||
"version": "0.4.1", | ||
"version": "0.5.0", | ||
"description": "Cordova File Cache", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -83,4 +83,5 @@ cordova-file-cache | ||
// When file is not cached, the original input is returned as a fallback. | ||
// When file is not cached, the server URL is returned as a fallback. | ||
cache.get('http://yoursever.com/never-cached-this.jpg') === 'http://yoursever.com/never-cached-this.jpg' | ||
cache.get('never-cached-this.jpg') === 'http://yoursever.com/never-cached-this.jpg' | ||
@@ -121,2 +122,6 @@ // Get Base64 encoded data URL. | ||
### 0.5.0 (15/11/2014) | ||
* Bugfix: Make sure cache returns a valid server URL if file is not cached. | ||
### 0.4.0 (13/11/2014) | ||
@@ -123,0 +128,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
26876
155