         task.resume()
     }
     
-    private static func generateUrl(with parameters: [String: String]) -> URL {
+    private static func generateUrl(with parameters: [String: String]) -> URL? {
         let characterSet = CharacterSet.urlPathAllowed
         
         let joined = parameters.reduce("collect?") { path, query in

        ]
        
        let arguments = queryArguments.combinedWith(parameters)
        let url = GoogleReporter.generateUrl(with: arguments)
        
        if !quietMode {
            print("Sending GA Report: ", url.absoluteString)

        
        // Make sure we generated a valid URL
        guard let url = URL(string: path, relativeTo: baseURL) else {
            print("GoogleReporter failed to generate a valid GA url for path ",
                  path, " relative to ", baseURL.absoluteString)
            return nil
        }
        
        return url
