When you call up the main screen, you choose what you want to do, in this I choose to register, when I go to the “opcoesCadastro” class I choose what I want to register, be it a client or a dependent, when I choose client I go to the “cadastroCliente” class in that I call two @Autowired, one for my “Customers” interface where I check whether the customer’s email is already registered, an error appears saying that “Cannot invoke “com.dev.spring.repository.Clientes.findByEmail( String)” because “this.clientes” is null”
I’m hoping to be able to check whether the customer’s email is already registered or not, but it always gives the error that “this.clientes” is null
Luis Gustavo Soares Oliveira is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.