aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/river.php
diff options
context:
space:
mode:
authorBrett Profitt <brett.profitt@gmail.com>2011-09-29 18:16:03 -0700
committerBrett Profitt <brett.profitt@gmail.com>2011-09-29 18:16:03 -0700
commitbfdb9bb8a87a29038ba1ae25355684ae19678fdd (patch)
treea074e2d6bfa19c17b284c3950b4555cf584eabe2 /engine/lib/river.php
parent7be23080f34a8f92ca1f8d49c3aa0e6ce3472f4c (diff)
parenta458ae4e0f8e5b19884860fead6e5f901b95eca4 (diff)
downloadelgg-bfdb9bb8a87a29038ba1ae25355684ae19678fdd.tar.gz
elgg-bfdb9bb8a87a29038ba1ae25355684ae19678fdd.tar.bz2
Merge branch 'master' of github.com:brettp/Elgg
Diffstat (limited to 'engine/lib/river.php')
-rw-r--r--engine/lib/river.php14
1 files changed, 7 insertions, 7 deletions
diff --git a/engine/lib/river.php b/engine/lib/river.php
index 64ddcfdc1..e283c0595 100644
--- a/engine/lib/river.php
+++ b/engine/lib/river.php
@@ -170,9 +170,6 @@ function elgg_delete_river(array $options = array()) {
$wheres[] = "rv.posted <= {$options['posted_time_upper']}";
}
- // remove identical where clauses
- $wheres = array_unique($wheres);
-
// see if any functions failed
// remove empty strings on successful functions
foreach ($wheres as $i => $where) {
@@ -183,6 +180,9 @@ function elgg_delete_river(array $options = array()) {
}
}
+ // remove identical where clauses
+ $wheres = array_unique($wheres);
+
$query = "DELETE rv.* FROM {$CONFIG->dbprefix}river rv ";
// remove identical join clauses
@@ -304,9 +304,6 @@ function elgg_get_river(array $options = array()) {
}
}
- // remove identical where clauses
- $wheres = array_unique($wheres);
-
// see if any functions failed
// remove empty strings on successful functions
foreach ($wheres as $i => $where) {
@@ -317,6 +314,9 @@ function elgg_get_river(array $options = array()) {
}
}
+ // remove identical where clauses
+ $wheres = array_unique($wheres);
+
if (!$options['count']) {
$query = "SELECT DISTINCT rv.* FROM {$CONFIG->dbprefix}river rv ";
} else {
@@ -378,7 +378,7 @@ function elgg_list_river(array $options = array()) {
'offset' => (int) max(get_input('offset', 0), 0),
'limit' => (int) max(get_input('limit', 20), 0),
'pagination' => TRUE,
- 'list_class' => 'elgg-river',
+ 'list_class' => 'elgg-list-river elgg-river', // @todo remove elgg-river in Elgg 1.9
);
$options = array_merge($defaults, $options);