diff options
Diffstat (limited to 'includes')
-rw-r--r-- | includes/class-giglogadmin-concert.php | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/includes/class-giglogadmin-concert.php b/includes/class-giglogadmin-concert.php index c277648..a470617 100644 --- a/includes/class-giglogadmin-concert.php +++ b/includes/class-giglogadmin-concert.php @@ -245,10 +245,7 @@ if ( ! class_exists( 'GiglogAdmin_Concert' ) ) { } $query .= ' ORDER BY wpgconcert_date'; - - if ( ! empty( $lmt ) ) { - $query .= " LIMIT {$offset},{$limit}"; - } + $query .= " LIMIT {$offset},{$limit}"; return $query; } @@ -272,12 +269,7 @@ if ( ! class_exists( 'GiglogAdmin_Concert' ) ) { // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared $results = $wpdb->get_results( $query ); - return array_map( - function( $c ) { - return new GiglogAdmin_Concert( $c ); - }, - $results - ); + return array_map( fn( $c ) => new GiglogAdmin_Concert( $c ), $results ); } /** |