Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

For you to Following #494

Closed
wants to merge 3 commits into from
Closed

For you to Following #494

wants to merge 3 commits into from

Conversation

msamgan
Copy link
Contributor

@msamgan msamgan commented Aug 8, 2024

@msamgan msamgan requested a review from nunomaduro August 8, 2024 00:11
@msamgan msamgan changed the title For you to follow For you to Follow Aug 8, 2024
@msamgan msamgan changed the title For you to Follow For you to Following Aug 8, 2024
@msamgan
Copy link
Contributor Author

msamgan commented Aug 8, 2024

This Update will work as base update for #454 and #455 once merged.

@msamgan
Copy link
Contributor Author

msamgan commented Aug 26, 2024

@nunomaduro @MrPunyapal please have a look at this.

@@ -8,10 +8,10 @@
use App\Models\User;
use Illuminate\Database\Eloquent\Builder;

final readonly class QuestionsForYouFeed
final readonly class QuestionsFollowingFeed
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, it's not just about renaming file names.

Check queries in this file.

You need to change logic here too.

It must only show the posts from users which are followed by the current user.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I hear you, but the logic for follower and following is not touched at all. That makes the need to change in query, not required.

Its just the label and files names which will be impacted. At DB level there is no change hence no update in Query.

what am I missing ?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it should show what exactly the following means.

Copy link
Contributor Author

@msamgan msamgan Aug 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you please elaborate for better understanding ? Right now the "for you" section get all the questions which are suppose to be "Following".

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check the query.

It's not showing posts from the following of users.

It has some other logic.

It should show posts where the user is following $question->to.

Copy link
Contributor Author

@msamgan msamgan Aug 28, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the input @ojessecruz . I got that part, but the current query is doing exactly the same. That is what i did not undertand. What are the changes required.

The for you page right now shows the post from the people you are are following. The last line in the query (image above) shows the same. This is what I am confused about.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When you see orWhere that means it's not just including following posts it has some extra sutff that we need to remove 🙂

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ohhh.. This is what you meant. You meant only the post from followings. Right now it also shows the liked and replied posts by the following. Thanks for the explanation. I'll make the update tomorrow.

Thanks @MrPunyapal

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@msamgan are you there?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, was preoccupied in some family matter.
Will give you an updated PR by tomorrow...

@msamgan msamgan closed this Sep 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants