Skip to content

Commit

Permalink
storagePath variable scope bug
Browse files Browse the repository at this point in the history
  • Loading branch information
evermeer committed Aug 28, 2018
1 parent 527b854 commit 7e0bb56
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion EVURLCache.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Pod::Spec.new do |s|
#

s.name = "EVURLCache"
s.version = "3.5.0"
s.version = "3.6.0"
s.summary = "NSURLCache subclass for handeling all web requests that use NSURLRequest"
s.description = "This is a NSURLCache subclass for handeling all web requests that use NSURLRequest. (This includes UIWebView)"
s.homepage = "https://github.com/evermeer/EVURLCache"
Expand Down
4 changes: 2 additions & 2 deletions EVURLCache/Pod/EVURLCache.swift
Original file line number Diff line number Diff line change
Expand Up @@ -120,10 +120,10 @@ open class EVURLCache: URLCache {
}

// Check if there is a cache for this request
let storagePath = EVURLCache.storagePathForRequest(request, rootPath: EVURLCache._cacheDirectory) ?? ""
var storagePath = EVURLCache.storagePathForRequest(request, rootPath: EVURLCache._cacheDirectory) ?? ""
if !FileManager.default.fileExists(atPath: storagePath) {
EVURLCache.debugLog("CACHE not found \(storagePath)")
let storagePath = EVURLCache.storagePathForRequest(request, rootPath: EVURLCache._preCacheDirectory) ?? ""
storagePath = EVURLCache.storagePathForRequest(request, rootPath: EVURLCache._preCacheDirectory) ?? ""
if !FileManager.default.fileExists(atPath: storagePath) {
EVURLCache.debugLog("PRECACHE not found \(storagePath)")
return nil
Expand Down

0 comments on commit 7e0bb56

Please sign in to comment.