From ece85dc90354e01e482ebe061a2e177522a1d8d1 Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Fri, 9 Sep 2016 18:03:01 +0200 Subject: [PATCH] Remove remove_data arg for DownloadItem.cancel This was added in f0779f8cc043d68874660e5b3f7e03a077a01a3a but never actually used. --- qutebrowser/browser/webkit/downloads.py | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/qutebrowser/browser/webkit/downloads.py b/qutebrowser/browser/webkit/downloads.py index 17a234447..fa0f17640 100644 --- a/qutebrowser/browser/webkit/downloads.py +++ b/qutebrowser/browser/webkit/downloads.py @@ -481,12 +481,8 @@ class DownloadItem(QObject): self.stats.percentage(), system) @pyqtSlot() - def cancel(self, remove_data=True): - """Cancel the download. - - Args: - remove_data: Whether to remove the downloaded data. - """ + def cancel(self): + """Cancel the download.""" log.downloads.debug("cancelled") self._read_timer.stop() self.cancelled.emit() @@ -497,8 +493,7 @@ class DownloadItem(QObject): self.reply = None if self.fileobj is not None: self.fileobj.close() - if remove_data: - self.delete() + self.delete() self.done = True self.finished.emit() self.data_changed.emit()