Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi, thanks for this great module. It seems like every major social-networking site would use a module like this to keep a collection of favorites for a user.
I'd like to suggest that you make the favorite_node_get() funciton for this module 'public' (remove the leading underscore) so themers and other module don't have to rewrite a fetching script. Rounding out this feature, I'd also like to see the complement to this function where you pass in a node and it returns a list of users. I've attached a patch with these changes, please consider adding them to your module!
Thanks! -Nathan
Comment | File | Size | Author |
---|---|---|---|
#2 | favorite_nodes_db.patch.txt | 2.51 KB | aaron |
#1 | favorite_node_db_0.patch | 1.64 KB | quicksketch |
favorite_node_db.patch | 1.68 KB | quicksketch |
Comments
Comment #1
quicksketchHmm, the query in the first patch is bunk. Here's a proper retrieval of user data.
Comment #2
aaron CreditAttribution: aaron commented+1 to this patch. although it should have favorite_nodes_get always return at the very least array(). patch submitted.