]> git.mxchange.org Git - friendica-addons.git/commitdiff
Fix errors in leistungsschutzrecht addon
authorArt4 <art4@wlabs.de>
Sat, 30 Nov 2024 19:37:58 +0000 (19:37 +0000)
committerHypolite Petovan <hypolite@mrpetovan.com>
Thu, 12 Dec 2024 21:37:42 +0000 (22:37 +0100)
leistungsschutzrecht/leistungsschutzrecht.php

index f6c65399525f8919fd380a1aa639fe45d4ce3359..ec8091acb9127c3c3be8f462e66f9171df1df7fc 100644 (file)
@@ -6,7 +6,6 @@
  * Author: Michael Vogel <https://pirati.ca/profile/heluecht>
  */
 
-use Friendica\App;
 use Friendica\Core\Hook;
 use Friendica\Core\Logger;
 use Friendica\DI;
@@ -149,7 +148,7 @@ function leistungsschutzrecht_is_member_site(string $url): bool
        $cleanedurlpart = explode('%', $urldata['host']);
 
        $hostname = explode('.', $cleanedurlpart[0]);
-       if (empty($hostname)) {
+       if ($hostname === false || $hostname === '') {
                return false;
        }