Skip to content

Commit 87885fc

Browse files
committed
fix: selected_workspace is not defined
The var was added in PR #94, but generates an exception because is not defined. Rolling back to int(key) to address this. closes #95
1 parent a076161 commit 87885fc

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

app.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -872,13 +872,13 @@ def unhandled_input(self, key):
872872
return
873873

874874
# Workspace is selected
875-
if selected_workspace - 1 == self.workspaces_line.selected:
875+
if int(key) - 1 == self.workspaces_line.selected:
876876
return
877+
self.workspaces_line.select(int(key))
877878

878-
self.workspaces_line.select(selected_workspace)
879879
# Stop rtm to switch workspace
880880
self.real_time_task.cancel()
881-
return self.switch_to_workspace(selected_workspace)
881+
return self.switch_to_workspace(int(key))
882882
elif key == keymap['set_snooze']:
883883
return self.open_set_snooze()
884884

0 commit comments

Comments
 (0)