Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6e77325

Browse files
committed
Simplify a bit, remove preliminary computation of mode
1 parent 853f202 commit 6e77325

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

IPython/terminal/interactiveshell.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,9 +204,8 @@ def _validate_editing_mode(self, proposal):
204204

205205
@observe('editing_mode')
206206
def _editing_mode(self, change):
207-
u_mode = change.new.upper()
208207
if self.pt_app:
209-
self.pt_app.editing_mode = getattr(EditingMode, u_mode)
208+
self.pt_app.editing_mode = getattr(EditingMode, change.new.upper())
210209

211210
@observe('autoformatter')
212211
def _autoformatter_changed(self, change):

0 commit comments

Comments
 (0)