Browse Source

Use forward:/index.html for home page

Fixes gh-549
pull/543/merge
Dave Syer 12 years ago
parent
commit
e472e7ccca
  1. 3
      spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/web/WebMvcAutoConfiguration.java

3
spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/web/WebMvcAutoConfiguration.java

@ -238,7 +238,8 @@ public class WebMvcAutoConfiguration { @@ -238,7 +238,8 @@ public class WebMvcAutoConfiguration {
catch (IOException ex) {
// Ignore
}
registry.addViewController("/").setViewName("/index.html");
// Use forward: prefix so that no view resolution is done
registry.addViewController("/").setViewName("forward:/index.html");
return;
}
}

Loading…
Cancel
Save