mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2025-06-07 09:54:27 +02:00
Replace x() by !empty() or defaults()
- Remove extraneous parentheses around !empty()
This commit is contained in:
parent
074493a29e
commit
d836593a3b
42 changed files with 80 additions and 80 deletions
|
@ -103,7 +103,7 @@ function nsfw_addon_settings_post(&$a, &$b)
|
|||
|
||||
if (!empty($_POST['nsfw-submit'])) {
|
||||
PConfig::set(local_user(), 'nsfw', 'words', trim($_POST['nsfw-words']));
|
||||
$enable = (x($_POST, 'nsfw-enable') ? intval($_POST['nsfw-enable']) : 0);
|
||||
$enable = (!empty($_POST['nsfw-enable']) ? intval($_POST['nsfw-enable']) : 0);
|
||||
$disable = 1 - $enable;
|
||||
PConfig::set(local_user(), 'nsfw', 'disable', $disable);
|
||||
info(L10n::t('NSFW Settings saved.') . EOL);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue