mirror of https://gitee.com/stylefeng/roses
【7.2.2】修复spring mvc自动配置
parent
611b970530
commit
75ffce31c5
|
@ -2,6 +2,7 @@ package cn.stylefeng.roses.kernel.system.integration.config;
|
|||
|
||||
import cn.stylefeng.roses.kernel.system.integration.ErrorStaticJsonView;
|
||||
import org.springframework.boot.autoconfigure.AutoConfigureBefore;
|
||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
|
||||
import org.springframework.boot.autoconfigure.web.servlet.error.ErrorMvcAutoConfiguration;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
@ -23,6 +24,7 @@ public class RestErrorViewAutoConfiguration {
|
|||
* @date 2020/12/16 15:47
|
||||
*/
|
||||
@Bean("error")
|
||||
@ConditionalOnMissingBean(name = "error")
|
||||
public ErrorStaticJsonView error() {
|
||||
return new ErrorStaticJsonView();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue