     var name = String(url.path.dropFirst())
 
     let issuer: String
-    if let issuerString = queryDictionary[kQueryIssuerKey] {
+    if let issuerString = try queryItems.value(for: kQueryIssuerKey) {
         issuer = issuerString
     } else if let separatorRange = name.range(of: ":") {
         // If there is no issuer string, try to extract one from the name

    }
    return digits
}

        throw DeserializationError.missingFactor
    }

    let algorithm = try queryItems.value(for: kQueryAlgorithmKey).map(algorithmFromString) ?? defaultAlgorithm
    let digits = try queryItems.value(for: kQueryDigitsKey).map(parseDigits) ?? defaultDigits
    guard let secret = try externalSecret ?? queryItems.value(for: kQuerySecretKey).map(parseSecret) else {
        throw DeserializationError.missingSecret
    }
    guard let generator = Generator(factor: factor, secret: secret, algorithm: algorithm, digits: digits) else {
