Skip to content

Commit

Permalink
Fix issues reported by psalm 4.27
Browse files Browse the repository at this point in the history
  • Loading branch information
mstilkerich committed Sep 2, 2022
1 parent 12295a3 commit 696e3ba
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/CardDavClient.php
Expand Up @@ -582,8 +582,8 @@ public static function compareUrlPaths(string $url1, string $url2): bool
{
$comp1 = \Sabre\Uri\parse($url1);
$comp2 = \Sabre\Uri\parse($url2);
$p1 = trim(rtrim($comp1["path"], "/"), "/");
$p2 = trim(rtrim($comp2["path"], "/"), "/");
$p1 = trim(rtrim($comp1["path"] ?? '', "/"), "/");
$p2 = trim(rtrim($comp2["path"] ?? '', "/"), "/");
return $p1 === $p2;
}

Expand Down
2 changes: 1 addition & 1 deletion src/Services/Sync.php
Expand Up @@ -287,7 +287,7 @@ private function determineChangesViaETags(
|| ($etag !== $localCacheState[$uri])
) {
$changes[] = [
'uri' => $uri,
'uri' => $uri ?? '',
'etag' => $etag
];
}
Expand Down

0 comments on commit 696e3ba

Please sign in to comment.