Check that provided class implements IStorage in StorageManager::setBackend
- Add notice in admin if setting value change failed - Add notice in console if setting value change failed
This commit is contained in:
parent
f225a6c51a
commit
7e2e2f425e
3 changed files with 15 additions and 3 deletions
|
@ -1200,7 +1200,9 @@ function admin_page_site_post(App $a)
|
|||
* @var $storagebackend \Friendica\Model\Storage\IStorage
|
||||
*/
|
||||
$storagebackend = Strings::escapeTags(trim(defaults($_POST, 'storagebackend', '')));
|
||||
StorageManager::setBackend($storagebackend);
|
||||
if (!StorageManager::setBackend($storagebackend)) {
|
||||
info(L10n::t('Invalid storage backend setting value.'));
|
||||
}
|
||||
|
||||
// save storage backend form
|
||||
if (!is_null($storagebackend) && $storagebackend != "") {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue