The server is listening on 3000. My MySQL database is initialized.
RepositoryNotFoundError: No repository for "User" was found.
Looks like this entity is not registered in current "default" connection?
message: 'No repository for "User" was found. Looks like tes.js)
{his entity is not registered in current "default" connection?'
his entity is not registered in current "default" connection?'}
How can I fix this?
I encountered same problem, You might be trying to use method getRepository before database connection is established.
I solved this problem by using inside async function const connection = await createConnection() then await connection.driver.afterConnect().then() and then stuff like routes.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With