IntelliJ IDEA shows errors when using Spring's @Autowired annotation

前端 未结 26 2450
栀梦
栀梦 2020-12-07 15:40

IntelliJ IDEA is showing errors when I use Spring\'s @Autowired annotation in the class, but the class is functioning without any problem.

Here is this

26条回答
  •  醉酒成梦
    2020-12-07 15:48

    I fixed it by adding the supress warning:

     @SuppressWarnings("SpringJavaInjectionPointsAutowiringInspection")
     @Autowired
     private ....
    

提交回复
热议问题