Skip to content

Commit

Permalink
Wrong table; fixes #3038
Browse files Browse the repository at this point in the history
  • Loading branch information
trasher committed Oct 24, 2017
1 parent a1b5281 commit 004e7fd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion inc/item_operatingsystem.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ static function countForItem(CommonDBTM $item) {
$restrict = "`glpi_items_operatingsystems`.`operatingsystems_id` = `glpi_operatingsystems`.`id`
AND `glpi_items_operatingsystems`.`items_id` = '".$item->getField('id')."'
AND `glpi_items_operatingsystems`.`itemtype` = '".$item->getType()."'".
getEntitiesRestrictRequest(" AND ", "glpi_operatingsystems", '', '', true);
getEntitiesRestrictRequest(" AND ", self::getTable(), '', '', true);

$nb = countElementsInTable(['glpi_items_operatingsystems', 'glpi_operatingsystems'], $restrict);

Expand Down

0 comments on commit 004e7fd

Please sign in to comment.