Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions lib/Horde/Core/Prefs/Storage/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,17 @@ public function get($scope_ob)
{
global $registry;

/* Modern PSR-15 request paths (e.g. the admin REST API) never
* populate $GLOBALS['registry']. Config-file defaults are a
* best-effort layer atop user prefs; when we cannot reach the
* registry, return the scope unchanged and let downstream
* storage drivers (SQL etc.) supply real values. Same graceful
* fallback shape as the try/catch below for missing prefs.php
* files. */
if (!$registry instanceof Horde_Registry) {
return $scope_ob;
}

/* Read the configuration file.
* Values are in the $_prefs array. */
try {
Expand Down
Loading