Skip to content

Commit

Permalink
Improve URL condition
Browse files Browse the repository at this point in the history
  • Loading branch information
Christoffer Winterkvist committed Dec 21, 2015
1 parent 64a0e1f commit 8277cb5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Source/Compass.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ public struct Compass {
var result = false
let query = url.absoluteString.substringFromIndex(scheme.endIndex)

guard !query.containsString("/") else { return parseAsURL(url, completion: completion) }
guard !query.containsString("/?") || !query.containsString("/#")
else { return parseAsURL(url, completion: completion) }

for route in routes.sort({ $0 < $1 }) {
guard let prefix = (route.characters
Expand Down

0 comments on commit 8277cb5

Please sign in to comment.