     }
     
     /**
-    Callback when download is completed, whether fail or success
-    */
+     Callback when download is completed, whether fail or success
+     */
     public func downloadCompletionCallback(request: NSURLRequest?, response: NSHTTPURLResponse?, result: NSData?, error: NSError?) {
         self.endBackgroundTask()
         self.completeOperation()

    }
    
    /**
    Cancel download task
    */
    public override func cancel() {
        self.delegate = nil
        super.cancel()

    
    // MARK: - Functions
    /**
     Start download task
     */
    public override func start() {
        super.start()
        if NSFileManager.defaultManager().fileExistsAtPath(self.destinationPathUrl!.path!) && !self.shouldOverwrite {
            self.completeOperation()
            self.delegate?.downloadTask?(self, completedWithFileURL: self.destinationPathUrl!)
            return
        }
        // start background downloading task
        self.backgroundTaskIdentifier = UIApplication.sharedApplication().beginBackgroundTaskWithExpirationHandler({ () -> Void in
            // task expired
