Skip to content

Commit 7a688e5

Browse files
committed
fix: Remove unnecessary if guard for active profile in whoami
#13 Branch: Profiles-13 Signed-off-by: Gabe Goodhart <ghart@us.ibm.com>
1 parent 8bf63e0 commit 7a688e5

1 file changed

Lines changed: 8 additions & 9 deletions

File tree

cforge/commands/settings/whoami.py

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,14 @@ def whoami() -> None:
2525
active_profile = get_active_profile()
2626

2727
# Display active profile information if available
28-
if active_profile:
29-
console.print("[bold cyan]Active Profile:[/bold cyan]")
30-
console.print(f" [cyan]Name:[/cyan] {active_profile.name}")
31-
console.print(f" [cyan]ID:[/cyan] {active_profile.id}")
32-
console.print(f" [cyan]Email:[/cyan] {active_profile.email}")
33-
console.print(f" [cyan]API URL:[/cyan] {active_profile.api_url}")
34-
if active_profile.metadata and active_profile.metadata.environment:
35-
console.print(f" [cyan]Environment:[/cyan] {active_profile.metadata.environment}")
36-
console.print()
28+
console.print("[bold cyan]Active Profile:[/bold cyan]")
29+
console.print(f" [cyan]Name:[/cyan] {active_profile.name}")
30+
console.print(f" [cyan]ID:[/cyan] {active_profile.id}")
31+
console.print(f" [cyan]Email:[/cyan] {active_profile.email}")
32+
console.print(f" [cyan]API URL:[/cyan] {active_profile.api_url}")
33+
if active_profile.metadata and active_profile.metadata.environment:
34+
console.print(f" [cyan]Environment:[/cyan] {active_profile.metadata.environment}")
35+
console.print()
3736

3837
# Display authentication status
3938
if env_token:

0 commit comments

Comments
 (0)