From 8238766e4c37e49068d8f2f5d5fdc53aa3822952 Mon Sep 17 00:00:00 2001 From: provokateurin Date: Mon, 27 Jul 2026 07:30:05 +0200 Subject: [PATCH] fix(rector-strict): Ignore wrong cases of RemoveReturnTagIncompatibleWithNativeTypeRector Signed-off-by: provokateurin --- build/rector-strict.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/build/rector-strict.php b/build/rector-strict.php index 18711ce0cce0e..ea694149bb3c2 100644 --- a/build/rector-strict.php +++ b/build/rector-strict.php @@ -6,6 +6,7 @@ */ use Rector\DeadCode\Rector\ClassMethod\RemoveDuplicatedReturnSelfDocblockRector; +use Rector\DeadCode\Rector\ClassMethod\RemoveReturnTagIncompatibleWithNativeTypeRector; use Rector\Php81\Rector\Property\ReadOnlyPropertyRector; use Rector\Php82\Rector\Class_\ReadOnlyClassRector; use Rector\PHPUnit\CodeQuality\Rector\Class_\AddSeeTestAnnotationRector; @@ -77,6 +78,10 @@ $nextcloudDir . '/core/Listener/RestrictInteractionListener.php', $nextcloudDir . '/apps/files_sharing/lib/Listener/RestrictInteractionListener.php', ], + RemoveReturnTagIncompatibleWithNativeTypeRector::class => [ + $nextcloudDir . '/lib/public/Sharing/Property/ISharePropertyType.php', + $nextcloudDir . '/lib/public/Sharing/Property/ShareProperty.php', + ], // `@return $this` is more specific than the native `: self` on a // non-final type; removing it breaks psalm's // LessSpecificImplementedReturnType check (psalm-strict).