for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
<?php
namespace Rj\FrontendBundle\DependencyInjection\Compiler;
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
abstract class BaseCompilerPass implements CompilerPassInterface
{
protected function namespaceService($id)
return "rj_frontend.$id";
sprintf
$id
It is generally a best practice as it is often more readable to use concatenation instead of interpolation for variables inside strings.
// Instead of $x = "foo $bar $baz"; // Better use either $x = "foo " . $bar . " " . $baz; $x = sprintf("foo %s %s", $bar, $baz);
}
It is generally a best practice as it is often more readable to use concatenation instead of interpolation for variables inside strings.