From a4624ffcfce0418050f98b140e792c1436c939a1 Mon Sep 17 00:00:00 2001 From: Geethanjali Eswaran Date: Wed, 30 Oct 2019 01:42:05 +0530 Subject: [PATCH] Rename variable to fix redefined-builtin warning --- rebound/rebound.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/rebound/rebound.py b/rebound/rebound.py index 850a018..20b395d 100644 --- a/rebound/rebound.py +++ b/rebound/rebound.py @@ -733,8 +733,8 @@ def __init__(self, search_results): self.main_loop.run() - def _handle_input(self, input): - if input == "enter": # View answers + def _handle_input(self, input_val): + if input_val == "enter": # View answers url = self._get_selected_link() if url != None: @@ -755,18 +755,18 @@ def _handle_input(self, input): ]) self.main_loop.widget = urwid.Frame(body=urwid.Overlay(linebox, self.content_container, "center", ("relative", 60), "middle", 23), footer=menu) - elif input in ('b', 'B'): # Open link + elif input_val in ('b', 'B'): # Open link url = self._get_selected_link() if url != None: webbrowser.open(url) - elif input == "esc": # Close window + elif input_val == "esc": # Close window if self.viewing_answers: self.main_loop.widget = self.original_widget self.viewing_answers = False else: raise urwid.ExitMainLoop() - elif input in ('q', 'Q'): # Quit + elif input_val in ('q', 'Q'): # Quit raise urwid.ExitMainLoop()