Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4e60b9d

Browse files
committed
[Routing][ObjectLoader] Remove forgotten deprecation after merge
1 parent 9dbeab9 commit 4e60b9d

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/Symfony/Component/Routing/Loader/ObjectLoader.php

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,10 @@ abstract protected function getObject(string $id);
4242
*/
4343
public function load($resource, string $type = null)
4444
{
45-
if (!preg_match('/^[^\:]+(?:::?(?:[^\:]+))?$/', $resource)) {
45+
if (!preg_match('/^[^\:]+(?:::(?:[^\:]+))?$/', $resource)) {
4646
throw new \InvalidArgumentException(sprintf('Invalid resource "%s" passed to the %s route loader: use the format "object_id::method" or "object_id" if your object class has an "__invoke" method.', $resource, \is_string($type) ? '"'.$type.'"' : 'object'));
4747
}
4848

49-
if (1 === substr_count($resource, ':')) {
50-
$resource = str_replace(':', '::', $resource);
51-
@trigger_error(sprintf('Referencing object route loaders with a single colon is deprecated since Symfony 4.1. Use %s instead.', $resource), E_USER_DEPRECATED);
52-
}
53-
5449
$parts = explode('::', $resource);
5550
$method = $parts[1] ?? '__invoke';
5651

0 commit comments

Comments
 (0)