From 87cecce26318f0409b8dfafbac9d4a6b924de6f8 Mon Sep 17 00:00:00 2001 From: David Diaz Date: Sat, 21 Oct 2017 01:24:49 -0600 Subject: [PATCH] Added a validation for when the quick panel is cancelled. --- beau.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/beau.py b/beau.py index 6e5fd00..91559c8 100644 --- a/beau.py +++ b/beau.py @@ -51,12 +51,13 @@ class BeauCommand(sublime_plugin.TextCommand): self.requests.append([method, alias, endpoint]) requests.append([title, description]) - - proc.wait() active_window.show_quick_panel(requests, self.on_done) def on_done(self, index): + if index == -1: + return + active_window = sublime.active_window() active_view = active_window.active_view()