WordPress.org

Making WordPress.org

Opened 2 years ago

Closed 23 months ago

Last modified 22 months ago

#2967 closed enhancement (fixed)

Support Forums: Add caching for user's topics and reviews count

Reported by: SergeyBiryukov Owned by: SergeyBiryukov
Milestone: Priority: normal
Component: Support Forums Keywords: has-patch dev-feedback
Cc:

Description

#2772 introduced two functions to get user's topics or reviews count:

  • wporg_support_get_user_topics_count()
  • wporg_support_get_user_reviews_count()

These counts should be cached, and posting a new topic or review should bust the cache.

Attachments (1)

2967.patch (1.9 KB) - added by ketuchetan 2 years ago.

Download all attachments as: .zip

Change History (10)

#1 @SergeyBiryukov
2 years ago

  • Type changed from defect to enhancement

@ketuchetan
2 years ago

#2 @ketuchetan
2 years ago

  • Keywords has-patch dev-feedback added

Hi @SergeyBiryukov,

I have added my patch. Could you please check and let me know if you have any changes on that.

This ticket was mentioned in Slack in #meta by chetansatasiya. View the logs.


23 months ago

#4 @SergeyBiryukov
23 months ago

  • Owner set to SergeyBiryukov
  • Status changed from new to reviewing

#5 @SergeyBiryukov
23 months ago

In 5860:

Support Forums: Introduce Users::get_user_topics_count() and ::get_user_reviews_count() methods.

The code is relocated from the wporg-support theme.

See #2967, #2772.

#6 @SergeyBiryukov
23 months ago

In 5861:

Support Theme: Use the methods added in [5860] in wporg_support_get_user_topics_count() and wporg_support_get_user_reviews_count().

See #2967, #2772.

#7 @SergeyBiryukov
23 months ago

  • Resolution set to fixed
  • Status changed from reviewing to closed

In 5862:

Support Forums: Add caching for user's topics and reviews count queries.

Props ketuchetan for initial patch.
Fixes #2967.

#8 @SergeyBiryukov
23 months ago

In 5866:

Support Forums: Correct description for Users::get_user_reviews_count().

See #2967.

#9 @SergeyBiryukov
22 months ago

In 5950:

Support Forums: Clear user's topics and reviews count cache on spamming/unspamming, approving/unapproving, and archiving/unarchiving a topic.

See #2967.

Note: See TracTickets for help on using tickets.