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

Return just the number of likes #8

Open
3 tasks
franeklubi opened this issue Sep 29, 2020 · 8 comments
Open
3 tasks

Return just the number of likes #8

franeklubi opened this issue Sep 29, 2020 · 8 comments
Assignees
Labels
good first issue Good for newcomers

Comments

@franeklubi
Copy link
Owner

franeklubi commented Sep 29, 2020

  • Return posts' and comments' likes as a number, not an array of likes
  • Make an endpoint to fetch users who liked a post
  • On the frontend - fetch only the number of likes (for posts and comments), DON'T fetch the users who liked, because there's no view to do that yet
@franeklubi franeklubi added the good first issue Good for newcomers label Sep 29, 2020
@macbookfilip
Copy link

Hello, I would like to try to working on this issue. Could you assign it to me please? Thank you

@franeklubi
Copy link
Owner Author

Hello, I would like to try to working on this issue. Could you assign it to me please? Thank you

Yes of course! 😊 Here You go

@franeklubi
Copy link
Owner Author

Don't be shy to reach out if You need any assistance at all!

@macbookfilip
Copy link

OK thank you so much. :)

@franeklubi franeklubi changed the title Return just a number of likes Return just the number of likes Oct 10, 2020
@franeklubi
Copy link
Owner Author

@macbookfilip Hi! how's the work on this issue going?

@macbookfilip
Copy link

hallo it's look be fine thanks

@macbookfilip
Copy link

hallo, i have question on you. Whoever can like these posts or just only logged user? But I think can be better with logged user. Do you want like and unlike or just like?

@franeklubi
Copy link
Owner Author

franeklubi commented Oct 29, 2020

Looking at the web.php file, You can clearly see that there is an auth guard on the path to the like controller

If You'd look into the like controller, then You would clearly see that the liking of a post/comment is handled already

So: only the logged in users can like posts/comments and the like logic is already handled

Have You used clubi? These questions seem like You've never even used the service You're trying to work on

The issue says that instead of the list of post's/comment's likes, You need to change the code to send just the number of likes

Then You'd need to create an endpoint that will return the list of like objects, so that the service doesn't lose the functionality if someone eventually wants to download the like info

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants