Project

General

Profile

« Previous | Next » 

Revision 44b93616

Added by Christian McDonald almost 3 years ago

Fix some config access bugs in pkg.php for PHP81. Fixes #13446

View differences:

src/usr/local/www/pkg.php
90 90
	}
91 91
}
92 92

  
93
$evaledvar = $config['installedpackages'][xml_safe_fieldname($pkg['name'])]['config'];
93
$config_path = sprintf('installedpackages/%s/config', xml_safe_fieldname($pkg['name']));
94

  
95
$evaledvar = config_get_path($config_path, []);
94 96

  
95 97
if ($_REQUEST['act'] == "update") {
96 98

  
......
147 149
ob_start();
148 150

  
149 151
$iflist = get_configured_interface_with_descr(true);
150
$evaledvar = $config['installedpackages'][xml_safe_fieldname($pkg['name'])]['config'];
152
$evaledvar = config_get_path($config_path, []);
151 153

  
152 154
if ($pkg['custom_php_global_functions'] != "") {
153 155
	eval($pkg['custom_php_global_functions']);

Also available in: Unified diff