Skip to content

Commit c85c4fe

Browse files
authored
Fix(core): revert breaking change (#934)
* Fix(core): revert bug introduced by phpstan refactor * adapt changelog
1 parent 807cad2 commit c85c4fe

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
77

88
## [UNRELEASE]
99

10+
### Fixed
11+
12+
- Fix of GLPI native fields update for objects with `fields` containers.
13+
1014
## [1.21.20] - 2025-03-20
1115

1216
### Fixed

inc/container.class.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1716,9 +1716,7 @@ public static function preItem(CommonDBTM $item)
17161716
$entities = getSonsOf(getTableForItemType('Entity'), $loc_c->fields['entities_id']);
17171717
}
17181718

1719-
//workaround: when a ticket is created from readdonly profile,
1720-
//it is not initialized; see https://github.com/glpi-project/glpi/issues/1438
1721-
if (!empty($item->fields)) {
1719+
if (count($item->fields) === 0) {
17221720
$item->fields = $item->input;
17231721
}
17241722

0 commit comments

Comments
 (0)