diff options
Diffstat (limited to 'src/client/executor.rs')
| -rw-r--r-- | src/client/executor.rs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/client/executor.rs b/src/client/executor.rs index 5fbba0b..6a017f8 100644 --- a/src/client/executor.rs +++ b/src/client/executor.rs @@ -9,11 +9,14 @@ pub(crate) struct Executor<'a> { } impl<'a> Executor<'a> { - pub(crate) fn new(task: impl IntoTask, args: String) -> Result<Self, IntoTaskErr> { + pub(crate) fn new( + task: impl IntoTask, + args: impl IntoIterator<Item = String>, + ) -> Result<Self, IntoTaskErr> { let task = task.into_task()?; Ok(Self { task: task, - args: Box::new([args]), + args: args.into_iter().collect(), output: None, }) } |
