It seems that the line await this.postTranslationRepository.save(translations); tries to cascade insert the update to the postEntity without setting the userId. the second INSERT in the log gets executed by the postTranslationRepository
Steps to reproduce:
Start the boilerplate application
Create a User through Swagger
Create a Post with 2 translations through Swagger, you'll get the exception in the logs
Trying to create a new Post through Swagger I get the following exception:
It seems that the line
await this.postTranslationRepository.save(translations);
tries to cascade insert the update to thepostEntity
without setting theuserId
. the secondINSERT
in the log gets executed by thepostTranslationRepository
Steps to reproduce: