From 406531924cfa36205e4a7aa65236545dc27e05f3 Mon Sep 17 00:00:00 2001 From: Ethan Dalool Date: Mon, 23 Mar 2020 19:57:12 -0700 Subject: [PATCH] Only call self.get_files if no path provided. Note that self.find(path) still calls get_files internally so it's going to happen either way -- this just removes a redundant call. --- src/mega/mega.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mega/mega.py b/src/mega/mega.py index 6596326..dafd05b 100644 --- a/src/mega/mega.py +++ b/src/mega/mega.py @@ -609,8 +609,8 @@ class Mega: return self.get_link(node) def export(self, path=None, node_id=None): - nodes = self.get_files() if node_id: + nodes = self.get_files() node = nodes[node_id] else: node = self.find(path)