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

前端 未结 26 2210
栀梦
栀梦 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 16:08

    I had this problem with only one service with constructor based dependency injection with 2019.2.4 version of IntelliJ. I found it helpful to change the name of the service (shift + f6) and then discard the changes from the git level.

提交回复
热议问题