From 231278a95948c1fc39056a4e7efc6ad950a41ecd Mon Sep 17 00:00:00 2001 From: StyleCI Bot Date: Mon, 14 Oct 2024 16:20:09 +0000 Subject: [PATCH] Apply fixes from StyleCI --- src/Api/AttachRelation.php | 2 +- src/Api/BasicUserAttributes.php | 14 +++++++++++--- src/Api/CurrentUserAttributes.php | 11 ++++++++++- 3 files changed, 22 insertions(+), 5 deletions(-) diff --git a/src/Api/AttachRelation.php b/src/Api/AttachRelation.php index 4f761ac..b8d50e0 100644 --- a/src/Api/AttachRelation.php +++ b/src/Api/AttachRelation.php @@ -24,7 +24,7 @@ public function __construct( protected SettingsRepositoryInterface $settings ) { } - + public function __invoke(PostSerializer $serializer, Post $post): ?Relationship { $viewIPs = $serializer->getActor()->can('viewIps', $post); diff --git a/src/Api/BasicUserAttributes.php b/src/Api/BasicUserAttributes.php index 7ab7565..3ed36e1 100644 --- a/src/Api/BasicUserAttributes.php +++ b/src/Api/BasicUserAttributes.php @@ -1,5 +1,14 @@ settings->get('fof-geoip.showFlag')) { $attributes['showIPCountry'] = (bool) $user->getPreference('showIPCountry'); } - + return $attributes; } } diff --git a/src/Api/CurrentUserAttributes.php b/src/Api/CurrentUserAttributes.php index 23f7bd9..506fba9 100644 --- a/src/Api/CurrentUserAttributes.php +++ b/src/Api/CurrentUserAttributes.php @@ -1,5 +1,14 @@ getActor()->can('fof-geoip.canSeeCountry')) { $attributes['canSeeCountry'] = true; } - + return $attributes; } }