Spring Unsatisfied dependency expressed through constructor argument with index 0 of type

后端 未结 4 1982
既然无缘
既然无缘 2021-02-07 22:24

The full message is

Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: 
    Error creating bean with name \'userRepositoryUserDetailsSe         


        
4条回答
  •  抹茶落季
    2021-02-07 23:13

    Annotatate your class implementing UserRepository with spring @Component annotation

    @Component
    public MyUserRepository implements UserRepository
    {
        User findByEmail(String email){
                return new User();
        }
    }
    

提交回复
热议问题