Skip to content

Commit 68a7dc1

Browse files
committed
Ensure bottom toolbar is only displayed if include_bottom_toolbar optional parameter is True
1 parent 29ca1f2 commit 68a7dc1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

cmd2/cmd2.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3269,13 +3269,13 @@ def get_prompt() -> Any:
32693269
return temp_session1.prompt(
32703270
prompt_to_use,
32713271
completer=completer_to_use,
3272-
bottom_toolbar=self._bottom_toolbar,
3272+
bottom_toolbar=self._bottom_toolbar if self.include_bottom_toolbar else None,
32733273
)
32743274

32753275
return self.session.prompt(
32763276
prompt_to_use,
32773277
completer=completer_to_use,
3278-
bottom_toolbar=self._bottom_toolbar,
3278+
bottom_toolbar=self._bottom_toolbar if self.include_bottom_toolbar else None,
32793279
)
32803280

32813281
# Otherwise read from self.stdin
@@ -3287,7 +3287,7 @@ def get_prompt() -> Any:
32873287
)
32883288
line = temp_session2.prompt(
32893289
prompt,
3290-
bottom_toolbar=self._bottom_toolbar,
3290+
bottom_toolbar=self._bottom_toolbar if self.include_bottom_toolbar else None,
32913291
)
32923292
if len(line) == 0:
32933293
raise EOFError
@@ -3299,7 +3299,7 @@ def get_prompt() -> Any:
32993299
output=self.session.output,
33003300
)
33013301
line = temp_session3.prompt(
3302-
bottom_toolbar=self._bottom_toolbar,
3302+
bottom_toolbar=self._bottom_toolbar if self.include_bottom_toolbar else None,
33033303
)
33043304
if len(line) == 0:
33053305
raise EOFError

0 commit comments

Comments
 (0)