fix: harden url mapping validation
This commit is contained in:
@@ -19,6 +19,13 @@ final class UrlMappingCollection {
|
||||
}
|
||||
|
||||
$this->mappings = array_values( $mappings );
|
||||
|
||||
usort(
|
||||
$this->mappings,
|
||||
static function ( UrlMapping $left, UrlMapping $right ): int {
|
||||
return strlen( $right->sourceUrl() ) <=> strlen( $left->sourceUrl() );
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user