1 config.inc | public ConfigDatabaseStorage::decode($raw) |
Decodes configuration data from the storage-specific format.
Parameters
string $raw: The raw configuration data string to decode.
Return value
array: The decoded configuration data as an associative array.
Overrides ConfigStorageInterface::decode
File
- core/
includes/ config.inc, line 1515 - This is the API for configuration storage.
Class
- ConfigDatabaseStorage
- Defines the database storage controller.
Code
public function decode($raw) {
// Use json_decode() directly for efficiency.
$contents = json_decode($raw, TRUE);
if (is_null($contents)) {
throw new ConfigStorageException('The configuration string could not be parsed.');
}
return $contents;
}