bind(this));
      },

      /**
      *  Cancels the upload
      */
      cancel: function() {
        return this.task ? this.task.cancel() : new Promise(function(resolve, reject) {
          reject('No task included')
        });
      },

      /**
      *  Resumes a paused upload
      */
      resume: function() {
        return this.task ? this.task.resume() : new Promise(function(resolve, reject) {
          reject('No task included')
        });
      },

      /**
      *  Pauses the upload
     