]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Fixes #4293 don't require both offset key and offset for listing stuff
authorcash <cash.costello@gmail.com>
Sat, 6 Jul 2013 02:31:56 +0000 (22:31 -0400)
committercash <cash.costello@gmail.com>
Sat, 6 Jul 2013 02:31:56 +0000 (22:31 -0400)
engine/lib/entities.php

index 226cf5c6c606718a2f20e0c5768563bafd29d598..997db79d26066508352eb017404a70c0030a87d2 100644 (file)
@@ -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,