- Timestamp:
- 11/25/2026 08:29:31 AM (10 days ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
foldrocket/trunk/src/Rest/Controllers/SmartViewsController.php
r3821266 r3822302 60 60 'callback' => array( $this, 'collection_assets' ), 61 61 'permission_callback' => array( $this, 'can_view' ), 62 'args' => array( 63 'include_total' => array( 64 'type' => 'boolean', 65 'default' => true, 66 'sanitize_callback' => 'rest_sanitize_boolean', 67 ), 68 ), 62 69 ), 63 70 ) … … 148 155 return $denied; 149 156 } 150 $collection = ( new CollectionRepository() )->find ( $this->int_param( $request, 'id' ) );157 $collection = ( new CollectionRepository() )->find_definition( $this->int_param( $request, 'id' ) ); 151 158 if ( ! $collection ) { 152 159 return $this->error( 'not_found', __( 'Smart view not found.', 'foldrocket' ), 404 ); … … 161 168 'page' => $page, 162 169 'per_page' => min( 100, max( 1, (int) $request->get_param( 'per_page' ) ?: 48 ) ), 170 '_include_total' => filter_var( $request->get_param( 'include_total' ), FILTER_VALIDATE_BOOLEAN, FILTER_NULL_ON_FAILURE ) ?? true, 163 171 ) 164 172 )
Note:
See TracChangeset
for help on using the changeset viewer.