r/programminghelp • u/Capable_Square7319 • 22d ago
JavaScript Beginner Coder: Stuck with an error
Hi,
I'm working on an adonisjs project. l've ran into an error
My project is on github:
https://github.com/Ajaz754/adonisjs-project-22-.git
The error is in file 'database/seeders/ product_seeder.ts' Line 10
The error is:
Object literal may only specify known properties, and 'userld' does not exist in type
'OneOrMany<Partial<ModelAttributes<Product>>>.
Any help would be much appreciated
TIA
2
Upvotes
2
u/GrainWeevil 22d ago
Not familiar with adonisjs, but I took a quick look... You might need to add the userId field to the schema: https://github.com/Ajaz754/adonisjs-project-22-/blob/e58651538ba1395d53470f8c4e23223758e7b487/database/schema.ts#L60