diff options
author | cash <cash.costello@gmail.com> | 2013-07-05 22:31:56 -0400 |
---|---|---|
committer | cash <cash.costello@gmail.com> | 2013-07-05 22:31:56 -0400 |
commit | 0dfe018f16e93aff5f046c08994a102e3f5d35e6 (patch) | |
tree | 40c9cfd540e482f25b34b371967d9dd1f111667e /engine | |
parent | 094b8f3afc75dac6520ea58d4e014b0e7f77d62a (diff) | |
download | elgg-0dfe018f16e93aff5f046c08994a102e3f5d35e6.tar.gz elgg-0dfe018f16e93aff5f046c08994a102e3f5d35e6.tar.bz2 |
Fixes #4293 don't require both offset key and offset for listing stuff
Diffstat (limited to 'engine')
-rw-r--r-- | engine/lib/entities.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/engine/lib/entities.php b/engine/lib/entities.php index 226cf5c6c..997db79d2 100644 --- a/engine/lib/entities.php +++ b/engine/lib/entities.php @@ -1473,8 +1473,10 @@ function elgg_list_entities(array $options = array(), $getter = 'elgg_get_entiti global $autofeed; $autofeed = true; + $offset_key = isset($options['offset_key']) ? $options['offset_key'] : 'offset'; + $defaults = array( - 'offset' => (int) max(get_input('offset', 0), 0), + 'offset' => (int) max(get_input($offset_key, 0), 0), 'limit' => (int) max(get_input('limit', 10), 0), 'full_view' => TRUE, 'list_type_toggle' => FALSE, |