fix config

This commit is contained in:
DOHA 2015-02-26 16:01:45 +02:00
commit 4963e40898
1 changed files with 1 additions and 2 deletions

View File

@ -4,7 +4,6 @@ import java.util.Arrays;
import org.baeldung.web.RedditController; import org.baeldung.web.RedditController;
import org.baeldung.web.RestExceptionHandler; import org.baeldung.web.RestExceptionHandler;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Configuration;
@ -50,7 +49,7 @@ public class WebConfig extends WebMvcConfigurerAdapter {
} }
@Bean @Bean
public RedditController redditController(@Qualifier("redditRestTemplate") OAuth2RestTemplate redditRestTemplate) { public RedditController redditController(OAuth2RestTemplate redditRestTemplate) {
RedditController controller = new RedditController(); RedditController controller = new RedditController();
controller.setRedditRestTemplate(redditRestTemplate); controller.setRedditRestTemplate(redditRestTemplate);
return controller; return controller;