Skip to content

Commit 65bc4ec

Browse files
committed
Fix no output from cb token.
Here we fix a bug with `cb token` that was preventing it from providing any output. The issue was that we were switching on a string for the format instead of the enum for the format. This was due to a recent change on how the format is set via `cli.cr`.
1 parent dbba50b commit 65bc4ec

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

77
## [Unreleased]
8+
### Fixed
9+
- No output from `cb token`.
810

911
## [2.2.0] - 2022-08-19
1012
### Added

src/cb/token.cr

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ class CB::TokenAction < CB::Action
1818

1919
def run
2020
case @format
21-
when "header"
21+
when Format::Header
2222
output << "Authorization: Bearer #{token.token}"
23-
when "default"
23+
when Format::Default
2424
output << token.token
2525
end
2626
end

0 commit comments

Comments
 (0)