Skip to content

Commit

Permalink
Fix psalm
Browse files Browse the repository at this point in the history
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
  • Loading branch information
CarlSchwan committed Oct 20, 2022
1 parent 60ec5e6 commit 99a7529
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 12 deletions.
5 changes: 4 additions & 1 deletion apps/user_ldap/lib/Group_LDAP.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class Group_LDAP extends BackendUtility implements GroupInterface, IGroupLDAP, I

/** @var CappedMemoryCache<string[]> $cachedGroupMembers array of users with gid as key */
protected CappedMemoryCache $cachedGroupMembers;
/** @var CappedMemoryCache<string[]> $cachedGroupsByMember array of groups with uid as key */
/** @var CappedMemoryCache<array[]> $cachedGroupsByMember array of groups with uid as key */
protected CappedMemoryCache $cachedGroupsByMember;
/** @var CappedMemoryCache<string[]> $cachedNestedGroups array of groups with gid (DN) as key */
protected CappedMemoryCache $cachedNestedGroups;
Expand Down Expand Up @@ -1129,6 +1129,9 @@ public function groupExists($gid) {
}

/**
* @template T
* @param array<array-key, T> $listOfGroups
* @return array<array-key, T>
* @throws ServerNotAvailableException
* @throws Exception
*/
Expand Down
12 changes: 1 addition & 11 deletions build/psalm-baseline.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1628,20 +1628,10 @@
<ParadoxicalCondition occurrences="1"/>
</file>
<file src="apps/user_ldap/lib/Group_LDAP.php">
<InvalidReturnStatement occurrences="1">
<code>$groupName</code>
</InvalidReturnStatement>
<InvalidReturnType occurrences="1">
<code>bool</code>
</InvalidReturnType>
<InvalidScalarArgument occurrences="2">
<InvalidScalarArgument occurrences="1">
<code>$groupID</code>
<code>$groupID</code>
</InvalidScalarArgument>
<RedundantCondition occurrences="2">
<code>is_array($groupDNs)</code>
<code>is_array($list)</code>
</RedundantCondition>
</file>
<file src="apps/user_ldap/lib/Group_Proxy.php">
<ParamNameMismatch occurrences="1">
Expand Down

0 comments on commit 99a7529

Please sign in to comment.