[buddypress-trac] [BuddyPress Trac] #9017: `BP_Activity_Query::get_sql_for_clause()` can wrongly use `$wpdb->prepare()`

buddypress-trac noreply at wordpress.org
Mon Nov 6 05:36:15 UTC 2023


#9017: `BP_Activity_Query::get_sql_for_clause()` can wrongly use
`$wpdb->prepare()`
--------------------------+---------------------
 Reporter:  imath         |       Owner:  imath
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:  12.0.0
Component:  Activity      |     Version:
 Severity:  normal        |  Resolution:  fixed
 Keywords:  has-patch     |
--------------------------+---------------------
Changes (by imath):

 * owner:  (none) => imath
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"13634" 13634]:
 {{{
 #!CommitTicketReference repository="" revision="13634"
 Avoid `$wpdb->prepare()` wrong usage when getting favorited activities

 In the `BP_Activity_Query::get_sql_for_clause()` method, make sure the
 placeholder used with `$wpdb->prepare()` is an integer as expected when
 setting the `hide_sitewide` clause.

 Fixes #9017
 Closes https://github.com/buddypress/buddypress/pull/186
 }}}

-- 
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/9017#comment:2>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list