aboutsummaryrefslogtreecommitdiffstats
path: root/gui.py
diff options
context:
space:
mode:
authorNao Pross <np@0hm.ch>2020-10-23 00:47:12 +0200
committerNao Pross <np@0hm.ch>2020-10-23 00:47:12 +0200
commit56e669fa6f37112f928919198e7f6cec7c3c0f3c (patch)
tree330324ec4cf4458d9a451745494b0ed18125d199 /gui.py
parentFix config path (expand) error (diff)
downloadMuddle-56e669fa6f37112f928919198e7f6cec7c3c0f3c.tar.gz
Muddle-56e669fa6f37112f928919198e7f6cec7c3c0f3c.zip
Make PEP8 happy
Diffstat (limited to '')
-rw-r--r--gui.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/gui.py b/gui.py
index 32d4a9e..eb5fe86 100644
--- a/gui.py
+++ b/gui.py
@@ -111,7 +111,7 @@ class MoodleFetcher(QThread):
sectionsReq = self.api.core_course_get_contents(courseid = str(course["id"]))
if not sectionsReq:
- return
+ return []
sections = sectionsReq.json()
return sections
@@ -150,7 +150,7 @@ class MoodleTreeView(QTreeWidget):
@pyqtSlot(QTreeWidgetItem, int)
def onItemDoubleClicked(self, item, col):
log.debug(f"double clicked on item with type {str(item.metadata.type)}")
- if item.type == MoodleItem.Type.FILE:
+ if item.metadata.type == MoodleItem.Type.FILE:
# TODO: download in a temp folder and open
pass