             completion(nil)
             return
         }
-        
-        guard let siteURL = siteURL else {
-            completion(UploadError.MissingNightscoutURL)
-            return
-        }
-        
-        guard let APISecret = APISecret else {
-            completion(UploadError.MissingAPISecret)
-            return
-        }
-
-        
         
         let uploadURL = siteURL.URLByAppendingPathComponent(endpoint)
         let request = NSMutableURLRequest(URL: uploadURL)

    
    public func checkAuth(completion: (ErrorType?) -> Void) {
        
        guard let siteURL = siteURL else {
            completion(UploadError.MissingNightscoutURL)
            return
        }
        
        guard let APISecret = APISecret else {
            completion(UploadError.MissingAPISecret)
            return
        }
        
        let testURL = siteURL.URLByAppendingPathComponent(defaultNightscoutAuthTestPath)
        
        let request = NSMutableURLRequest(URL: testURL)

        lastStoredTreatmentTimestamp = nil
    }

    public init(siteURL: NSURL, APISecret: String) {
        self.siteURL = siteURL
        self.APISecret = APISecret
        
