| @@ -1,8 +1,8 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | 3 | * @package FireBox |
| 4 | - * @version 3.1.13 Free | |
| 4 | + * @version 3.1.14 Free | |
| 5 | 5 | * |
| 6 | 6 | * @author FirePlugins <[email protected]> |
| 7 | 7 | * @link https://www.fireplugins.com |
| 8 | 8 | * @copyright Copyright © 2026 FirePlugins All Rights Reserved |
| @@ -670,8 +670,16 @@ | ||
| 670 | 670 | * @return void |
| 671 | 671 | */ |
| 672 | 672 | public static function resetBoxStats($box_ids) |
| 673 | 673 | { |
| 674 | + // These ids are concatenated into raw IN() clauses below, so cast them here rather | |
| 675 | + // than trusting every caller to do it. | |
| 676 | + $box_ids = array_filter(array_map('intval', (array) $box_ids)); | |
| 677 | + if (empty($box_ids)) | |
| 678 | + { | |
| 679 | + return; | |
| 680 | + } | |
| 681 | + | |
| 674 | 682 | $logs_table = firebox()->tables->boxlog->getFullTableName(); |
| 675 | 683 | $logs_details_table = firebox()->tables->boxlogdetails->getFullTableName(); |
| 676 | 684 | |
| 677 | 685 | // delete box logs details |