Skip to content

Commit

Permalink
Change an exception message
Browse files Browse the repository at this point in the history
  • Loading branch information
GuilhemN committed Feb 14, 2016
1 parent 8896dd3 commit 6593189
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions Metadata/MetadataConverter.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,7 @@ public function convert(ClassHierarchyMetadata $metadata)
}

if ($classMetadata->initMethod) {
if (!method_exists($definition, 'setInitMethod')) {
throw new \RuntimeException(sprintf('@AfterSetup is not available on your Symfony version.'));
}

$definition->setInitMethod($classMetadata->initMethod);
throw new \RuntimeException(sprintf('You can\'t use @AfterSetup on a service.'));
}

$definitions[$classMetadata->id] = $definition;
Expand Down

0 comments on commit 6593189

Please sign in to comment.