Skip to content

Commit 5240e0e

Browse files
committed
Replace Guzzle with native Uri-capabilities
1 parent f2cfb3a commit 5240e0e

3 files changed

Lines changed: 3 additions & 5 deletions

File tree

composer.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@
4343
"ext-pcre": "*",
4444
"ext-spl": "*",
4545

46-
"guzzlehttp/psr7": "~2.8",
4746
"psr/clock": "~1.0",
4847
"simplesamlphp/assert": "~3.0",
4948
"simplesamlphp/composer-xmlprovider-installer": "~1.3"

src/XMLSchema/Type/AnyURIValue.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,11 @@
44

55
namespace SimpleSAML\XMLSchema\Type;
66

7-
use GuzzleHttp\Psr7\Uri;
8-
use GuzzleHttp\Psr7\UriNormalizer;
97
use SimpleSAML\XML\Assert\Assert;
108
use SimpleSAML\XMLSchema\Exception\SchemaViolationException;
119
use SimpleSAML\XMLSchema\Type\Interface\AbstractAnySimpleType;
1210
use SimpleSAML\XMLSchema\Type\Interface\ValueTypeInterface;
11+
use Uri\Rfc3986\Uri;
1312

1413
/**
1514
* @package simplesaml/xml-common
@@ -57,6 +56,6 @@ public function equals(ValueTypeInterface|string $other): bool
5756
$selfUri = new Uri($this->getValue());
5857
$otherUri = new Uri($other->getValue());
5958

60-
return UriNormalizer::isEquivalent($selfUri, $otherUri);
59+
return $selfUri->equals($otherUri);
6160
}
6261
}

tests/XMLSchema/Type/AnyURIValueTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ public function testEquals(): void
5050
$this->assertTrue(AnyURIValue::fromString('hello')->equals('hello'));
5151
$this->assertTrue(
5252
AnyURIValue::fromString('https://simplesamlphp.org/index.html')
53-
->equals('https://simplesamlphp.org:443/index.html'),
53+
->equals('HTTPS://simplesamlphp.org/index.html'),
5454
);
5555

5656
// Assert that two different values are not equal

0 commit comments

Comments
 (0)