Skip to:
Content

BuddyPress.org

Opened 16 years ago

Closed 16 years ago

#2098 closed enhancement (fixed)

[patch] BP_Activity_Activity::get_filter_sql() should be using IN operator for list queries HAS-PATCH

Reported by: MrMaz Owned by: MrMaz
Priority: major Milestone: 1.5
Component: Core Version:
Severity: Keywords: activity filter get_filter_sql has-patch
Cc:

Description

Here is a patch to improve the performance and security of the activity get() queries that rely on lists of ids, actions etc by utilizing the IN operator and also by passing all data through prepare.

Attachments (1)

bp-activity-classes.php.patch (3.9 KB ) - added by MrMaz 16 years ago.

Download all attachments as: .zip

Change History (6)

#1 @MrMaz
16 years ago

Forgot to mention that this patch has NOT been tested yet.

#2 @MrMaz
16 years ago

  • Keywords has-patch added
  • Summary BP_Activity_Activity::get_filter_sql() should be using IN operator for list queriesBP_Activity_Activity::get_filter_sql() should be using IN operator for list queries HAS-PATCH

#3 @DJPaul
16 years ago

  • ComponentCore
  • Owner set to MrMaz
  • Status newassigned

One of yours, MrMaz ;)

#4 @paulhastings0
16 years ago

  • Summary BP_Activity_Activity::get_filter_sql() should be using IN operator for list queries HAS-PATCH[patch] BP_Activity_Activity::get_filter_sql() should be using IN operator for list queries HAS-PATCH

#5 @mrmaz
16 years ago

  • Resolutionfixed
  • Status assignedclosed

(In [3345]) fixes #2098, IN operator is better than OR

Note: See TracTickets for help on using tickets.