| @@ -14,12 +14,11 @@ | ||
| 14 | 14 | global $wpdb; |
| 15 | 15 | $tablename = $wpdb->prefix . 'bitforms_reports'; |
| 16 | 16 | |
| 17 | 17 | // $latestIds = $wpdb->get_results("SELECT MAX(`id`) as latest_id FROM $tablename GROUP BY `context`"); |
| 18 | - // Direct query: table name from $wpdb->prefix concatenation (no user input). $wpdb->prepare() cannot parameterize table names. | |
| 19 | 18 | $wpdb->query( |
| 20 | 19 | $wpdb->prepare( |
| 21 | - "SELECT MAX(`id`) as latest_id FROM `{$tablename}` GROUP BY `context`" | |
| 20 | + "SELECT MAX(`id`) as latest_id FROM $tablename GROUP BY `context`" | |
| 22 | 21 | ) |
| 23 | 22 | ); |
| 24 | 23 | $latestIds = $wpdb->last_result; |
| 25 | 24 | |
| @@ -38,9 +37,9 @@ | ||
| 38 | 37 | ['id'] |
| 39 | 38 | ); |
| 40 | 39 | |
| 41 | 40 | $details = [ |
| 42 | - 'report_name' => __('All Entries', 'bit-form'), | |
| 41 | + 'report_name' => 'All Entries', | |
| 43 | 42 | 'hiddenColumns' => [], |
| 44 | 43 | 'pageSize' => 10, |
| 45 | 44 | 'sortBy' => [], |
| 46 | 45 | 'filters' => [], |