Apply suggestions from code review

Co-authored-by: Philipp <admin+Github@philipp.info>
This commit is contained in:
Michael Vogel 2021-11-07 14:02:13 +01:00 committed by GitHub
parent cff3dd67b0
commit 8fea67dade
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 29 additions and 29 deletions

View file

@ -78,12 +78,12 @@ function impressum_show($a,&$b) {
}
function impressum_addon_admin_post (&$a) {
$owner = (!empty($_POST['owner']) ? trim($_POST['owner']) : '');
$ownerprofile = (!empty($_POST['ownerprofile']) ? trim($_POST['ownerprofile']) : '');
$postal = (!empty($_POST['postal']) ? (trim($_POST['postal'])) : '');
$notes = (!empty($_POST['notes']) ? (trim($_POST['notes'])) : '');
$email = (!empty($_POST['email']) ? trim($_POST['email']) : '');
$footer_text = (!empty($_POST['footer_text']) ? (trim($_POST['footer_text'])) : '');
$owner = trim($_POST['owner'] ?? '');
$ownerprofile = trim($_POST['ownerprofile'] ?? '');
$postal = trim($_POST['postal'] ?? '');
$notes = trim($_POST['notes'] ?? '');
$email = trim($_POST['email'] ?? '');
$footer_text = trim($_POST['footer_text'] ?? '');
DI::config()->set('impressum','owner',strip_tags($owner));
DI::config()->set('impressum','ownerprofile',strip_tags($ownerprofile));
DI::config()->set('impressum','postal',strip_tags($postal));