[SOLVED] error[E0599]: no function or associated item named `belonging_to` found for struct `Post` in the current scope

Hello! I'm getting the error message

error[E0599]: no function or associated item named belonging_to found for struct Post in the current scope
--> src/lib.rs:53:26
|
53 | diesel::delete(Post::belonging_to(user))
| ^^^^^^^^^^^^ function or associated item not found in Post
|
::: src/models.rs:43:1
|
43 | pub struct Post {
| --------------- function or associated item belonging_to not found for this struct
|
= help: items from traits can only be used if the trait is implemented and in scope
= note: the following trait defines an item belonging_to, perhaps you need to implement it:
candidate #1: BelongingToDsl

I'm using Diesel and can't understand why I'm getting this so I decided to turn to you for help. (You don't have to help me, but thank you if you do, and thank you if you don't fix it but still try to help, and thank you if you don't try but read this.)

The repo:

Edit: somehow i fixed it whatt??? i dont even know what the issue was lmao

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.