diff --git a/crates/cuddle-ci/src/cli.rs b/crates/cuddle-ci/src/cli.rs index 953615f..c0ac090 100644 --- a/crates/cuddle-ci/src/cli.rs +++ b/crates/cuddle-ci/src/cli.rs @@ -43,25 +43,21 @@ impl CuddleCI { } } - pub fn with_pull_request(&mut self, pr: impl AsRef) -> &mut Self + pub fn with_pull_request(&mut self, pr: &T) -> &mut Self where T: PullRequestAction + ToOwned + Send + Sync + 'static, T: ToOwned, { - let pr = pr.as_ref(); - self.pr_action.push(Box::new(pr.to_owned())); self } - pub fn with_main(&mut self, main: impl AsRef) -> &mut Self + pub fn with_main(&mut self, main: &T) -> &mut Self where T: MainAction + Send + Sync + 'static, T: ToOwned, { - let main = main.as_ref(); - self.main_action.push(Box::new(main.to_owned())); self