WIP: welcom + error - 404 anstatt 500
[maven-thymeleaf-skin] / src / main / java / de / juplo / thymeproxy / Application.java
index ff5174a..03b106f 100644 (file)
@@ -5,10 +5,8 @@ import java.util.HashMap;
 import java.util.Locale;
 import java.util.Map;
 import org.apache.http.impl.client.CloseableHttpClient;
-import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.boot.SpringApplication;
 import org.springframework.boot.autoconfigure.SpringBootApplication;
-import org.springframework.boot.autoconfigure.web.ServerProperties;
 import org.springframework.context.annotation.Bean;
 import org.springframework.core.Ordered;
 import org.springframework.core.env.Environment;
@@ -25,10 +23,6 @@ import org.thymeleaf.templateresolver.TemplateResolver;
 @SpringBootApplication
 public class Application extends WebMvcConfigurerAdapter
 {
-  @Autowired
-  private ServerProperties properties;
-
-
   @Bean
   public RegexUrlHandlerMapping proxiedHandlerMapping(
       ProxyHttpRequestHandler proxy,
@@ -114,7 +108,7 @@ public class Application extends WebMvcConfigurerAdapter
   @Bean
   public View error(ThymeleafViewResolver resolver) throws Exception
   {
-    return resolver.resolveViewName("templates/error", Locale.getDefault());
+    return resolver.resolveViewName("templates/500", Locale.getDefault());
   }