Revert "Getting closer to multiline scripts (#2738)" (#2745)

This reverts commit e66bf70589.
This commit is contained in:
Jonathan Turner
2020-11-10 18:22:13 +13:00
committed by GitHub
parent e66bf70589
commit 5a75e11b0e
17 changed files with 160 additions and 262 deletions

View File

@@ -51,9 +51,9 @@ impl WholeStreamCommand for SubCommand {
tag,
));
}
match block.block[0].pipelines.get(0) {
Some(item) => match item.list.get(0) {
Some(ClassifiedCommand::Expr(expr)) => expr.clone(),
match block.block[0].list.get(0) {
Some(item) => match item {
ClassifiedCommand::Expr(expr) => expr.clone(),
_ => {
return Err(ShellError::labeled_error(
"Expected a condition",