Skip to content

Commit

Permalink
Update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
Hinton committed Apr 11, 2024
1 parent 0d093b8 commit a72b14e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion crates/bitwarden-cli/src/color.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ pub enum Color {
}

impl Color {
/**
* Evaluate if colors are supported
*/
pub fn is_enabled(self) -> bool {
match self {
Color::No => false,
Expand All @@ -18,7 +21,7 @@ impl Color {
}

/**
* Conditionally install color_eyre. If colors are disabled we also disable error colors.
* Installs color_eyre, if Color is disabled we use an empty theme to disable error colors.
*/
pub fn install_color_eyre(color: Color) -> color_eyre::Result<(), color_eyre::Report> {
if color.is_enabled() {
Expand Down

0 comments on commit a72b14e

Please sign in to comment.