@@ -6,7 +6,6 @@ import de.tschuehly.spring.viewcomponent.core.component.ViewComponentProperties
66import gg.jte.ContentType
77import gg.jte.TemplateEngine
88import gg.jte.springframework.boot.autoconfigure.JteViewResolver
9- import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean
109import org.springframework.boot.context.properties.EnableConfigurationProperties
1110import org.springframework.context.ApplicationContext
1211import org.springframework.context.annotation.Bean
@@ -19,19 +18,15 @@ import java.nio.file.Paths
1918@Import(ViewComponentAutoConfiguration ::class )
2019@EnableConfigurationProperties(ViewComponentProperties ::class )
2120class JteViewComponentAutoConfiguration (
22- private val viewComponentProperties : ViewComponentProperties ,
23- private val applicationContext : ApplicationContext
21+ private val viewComponentProperties : ViewComponentProperties
2422) {
2523 @Bean
2624 fun jteViewContextAspect (templateEngine : TemplateEngine ): JteViewContextAspect {
2725 return JteViewContextAspect (templateEngine, viewComponentProperties)
2826 }
2927
3028 @Bean
31- @ConditionalOnMissingBean(
32- JteViewResolver ::class
33- )
34- fun jteViewResolver (templateEngine : TemplateEngine ): JteViewResolver {
29+ fun jteViewComponentResolver (templateEngine : TemplateEngine ): JteViewResolver {
3530 if (! StringUtils .hasText(viewComponentProperties.jteTemplateSuffix)){
3631 throw ViewComponentException (" You need to set jteTemplateSuffix" )
3732 }
0 commit comments