Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue using Mattress with CocoaPods & Swift 2.3 #43

Open
erawhctim opened this issue Dec 20, 2016 · 0 comments
Open

Issue using Mattress with CocoaPods & Swift 2.3 #43

erawhctim opened this issue Dec 20, 2016 · 0 comments
Assignees

Comments

@erawhctim
Copy link

When including Mattress via CocoaPods and manually specifying the SWIFT_VERSION to 2.3, I get a compilation error with DiskCache.diskPath() (line 457):

if !NSFileManager.defaultManager().fileExistsAtPath(fileURL.absoluteString, isDirectory: &isDir) {
...
}

The issue stems from the fact that NSFileManager.fileExistsAtPath(...) accepts a non-optional string, so fileURL.absoluteString has to be unwrapped.

I pushed a fix to my own fork and raised a PR - just not too sure if my solution is the most ideal given the rest of the context of DiskCache. Let me know what you think 👍

@dmauro dmauro self-assigned this Jan 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants