Skip to content

Commit

Permalink
fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
jreidinger committed Jul 19, 2023
1 parent 3f8874d commit d4cdb6f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion rust/agama-cli/src/questions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ async fn set_mode(value: Modes) -> anyhow::Result<()> {
pub async fn run(subcommand: QuestionsCommands) -> anyhow::Result<()> {
match subcommand {
QuestionsCommands::Mode(value) => set_mode(value.value).await,
QuestionsCommands::Answers { path } => {
QuestionsCommands::Answers { path: _ } => {
log::info!("TODO: implement answers");
Ok(())
}
Expand Down
8 changes: 3 additions & 5 deletions rust/agama-dbus-server/src/questions.rs
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ enum QuestionType {
}

/// Trait for objects that can provide answers to all kind of Question.
///
///
/// If not strategy is used or all defined strategies does not know answer,
/// then users need to answer it themself.
trait AnswerStrategy {
Expand Down Expand Up @@ -261,10 +261,8 @@ impl Questions {
if !self.interactive() {
self.answer_strategies.pop();
}
} else {
if self.interactive() {
self.answer_strategies.push(Box::new(DefaultAnswers {}));
}
} else if self.interactive() {
self.answer_strategies.push(Box::new(DefaultAnswers {}));
}
}

Expand Down

0 comments on commit d4cdb6f

Please sign in to comment.