I wanted to change the default upload limit, whatever input i used, also when i cange nothing, following error appereared:
/admin/config/media/file-settings
The website encountered an unexpected error. Please try again later.
Drupal\Core\Config\ImmutableConfigException: Can not set values on immutable configuration file_entity.settings:max_filesize. Use \Drupal\Core\Config\ConfigFactoryInterface::getEditable() to retrieve a mutable configuration object in Drupal\Core\Config\ImmutableConfig->set() (line 32 of core/lib/Drupal/Core/Config/ImmutableConfig.php).
When i go back to the previous page D8 shows following warning :
Warning: Invalid argument supplied for foreach() in Drupal\Core\Form\FormValidator->doValidateForm() (line 280 of core/lib/Drupal/Core/Form/FormValidator.php).
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | immutableconfigexception-on-file-settings-2650854-3.patch | 2.19 KB | esolitos |
| #2 | file_entity-change-file-settings-2650854-2.patch | 883 bytes | acke |
Comments
Comment #2
acke commentedThis patch change FormBase to ConfigFormBase.
Comment #3
esolitosI tested your patch and it looks all good, I'm using in production since a fre days now w/o any issue.
I added to the patch also a fix for the
#element_validatewhich needs to be an array.Comment #4
berdirLooks good, thanks.