From: Tobias Diekershoff Date: Thu, 19 Aug 2021 04:57:46 +0000 (+0200) Subject: use rtrim X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=a843e96c1f638d2d67ba91e185f02fe1b23c4b2f;p=friendica-addons.git use rtrim --- diff --git a/nitter/nitter.php b/nitter/nitter.php index 549356de..e8f3bcdb 100644 --- a/nitter/nitter.php +++ b/nitter/nitter.php @@ -37,10 +37,7 @@ function nitter_install() */ function nitter_addon_admin_post(App $a) { - $nitterserver = trim($_POST['nitterserver']); - if ((substr($apiurl, -1) == '/')) { - $apiurl = substr($apiurl, 0, -1); - } + $nitterserver = rtrim(trim($_POST['nitterserver']),'/'); DI::config()->set('nitter', 'server', $nitterserver); }