Remove unused Parser usage

This commit is contained in:
Janne Valkealahti
2021-12-18 16:17:10 +00:00
parent 4417d3e394
commit f20b71a8c2
2 changed files with 4 additions and 7 deletions

View File

@@ -46,8 +46,8 @@ public class ApplicationRunnerAutoConfiguration {
@Bean
@ConditionalOnProperty(prefix = SPRING_SHELL_INTERACTIVE, value = InteractiveShellApplicationRunner.ENABLED, havingValue = "true", matchIfMissing = true)
public ApplicationRunner interactiveApplicationRunner(Parser parser, Environment environment) {
return new InteractiveShellApplicationRunner(lineReader, promptProvider, parser, shell, environment);
public ApplicationRunner interactiveApplicationRunner(Environment environment) {
return new InteractiveShellApplicationRunner(lineReader, promptProvider, shell, environment);
}
@Bean

View File

@@ -19,7 +19,6 @@ package org.springframework.shell.jline;
import java.util.Collections;
import org.jline.reader.LineReader;
import org.jline.reader.Parser;
import org.jline.reader.UserInterruptException;
import org.jline.utils.AttributedString;
@@ -62,16 +61,14 @@ public class InteractiveShellApplicationRunner implements ApplicationRunner {
private final PromptProvider promptProvider;
private final Parser parser;
private final Shell shell;
private final Environment environment;
public InteractiveShellApplicationRunner(LineReader lineReader, PromptProvider promptProvider, Parser parser, Shell shell, Environment environment) {
public InteractiveShellApplicationRunner(LineReader lineReader, PromptProvider promptProvider, Shell shell,
Environment environment) {
this.lineReader = lineReader;
this.promptProvider = promptProvider;
this.parser = parser;
this.shell = shell;
this.environment = environment;
}