Skip to content

Commit 99a7529

Browse files
committed
Fix psalm
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
1 parent 60ec5e6 commit 99a7529

File tree

2 files changed

+5
-12
lines changed

2 files changed

+5
-12
lines changed

apps/user_ldap/lib/Group_LDAP.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ class Group_LDAP extends BackendUtility implements GroupInterface, IGroupLDAP, I
5757

5858
/** @var CappedMemoryCache<string[]> $cachedGroupMembers array of users with gid as key */
5959
protected CappedMemoryCache $cachedGroupMembers;
60-
/** @var CappedMemoryCache<string[]> $cachedGroupsByMember array of groups with uid as key */
60+
/** @var CappedMemoryCache<array[]> $cachedGroupsByMember array of groups with uid as key */
6161
protected CappedMemoryCache $cachedGroupsByMember;
6262
/** @var CappedMemoryCache<string[]> $cachedNestedGroups array of groups with gid (DN) as key */
6363
protected CappedMemoryCache $cachedNestedGroups;
@@ -1129,6 +1129,9 @@ public function groupExists($gid) {
11291129
}
11301130

11311131
/**
1132+
* @template T
1133+
* @param array<array-key, T> $listOfGroups
1134+
* @return array<array-key, T>
11321135
* @throws ServerNotAvailableException
11331136
* @throws Exception
11341137
*/

build/psalm-baseline.xml

+1-11
Original file line numberDiff line numberDiff line change
@@ -1628,20 +1628,10 @@
16281628
<ParadoxicalCondition occurrences="1"/>
16291629
</file>
16301630
<file src="apps/user_ldap/lib/Group_LDAP.php">
1631-
<InvalidReturnStatement occurrences="1">
1632-
<code>$groupName</code>
1633-
</InvalidReturnStatement>
1634-
<InvalidReturnType occurrences="1">
1635-
<code>bool</code>
1636-
</InvalidReturnType>
1637-
<InvalidScalarArgument occurrences="2">
1631+
<InvalidScalarArgument occurrences="1">
16381632
<code>$groupID</code>
16391633
<code>$groupID</code>
16401634
</InvalidScalarArgument>
1641-
<RedundantCondition occurrences="2">
1642-
<code>is_array($groupDNs)</code>
1643-
<code>is_array($list)</code>
1644-
</RedundantCondition>
16451635
</file>
16461636
<file src="apps/user_ldap/lib/Group_Proxy.php">
16471637
<ParamNameMismatch occurrences="1">

0 commit comments

Comments
 (0)