removed dead code and fixed CS
This commit is contained in:
parent
9538efaf40
commit
7d581471ce
@ -153,8 +153,6 @@ class DoctrineOrmTypeGuesser implements FormTypeGuesserInterface
|
||||
{
|
||||
$ret = $this->getMetadata($class);
|
||||
if ($ret && $ret[0]->hasField($property) && !$ret[0]->hasAssociation($property)) {
|
||||
$mapping = $ret[0]->getFieldMapping($property);
|
||||
|
||||
if (in_array($ret[0]->getTypeOfField($property), array('decimal', 'float'))) {
|
||||
return new ValueGuess(null, Guess::MEDIUM_CONFIDENCE);
|
||||
}
|
||||
|
@ -12,7 +12,6 @@
|
||||
namespace Symfony\Bridge\Monolog\Processor;
|
||||
|
||||
use Monolog\Processor\WebProcessor as BaseWebProcessor;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpKernel\Event\GetResponseEvent;
|
||||
use Symfony\Component\HttpKernel\HttpKernelInterface;
|
||||
|
||||
|
@ -11,7 +11,6 @@
|
||||
|
||||
namespace Symfony\Bundle\FrameworkBundle\Tests\Functional\Bundle\TestBundle\Controller;
|
||||
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\DependencyInjection\ContainerAware;
|
||||
|
||||
|
@ -240,7 +240,6 @@ class SecurityExtension extends Extension
|
||||
private function createFirewall(ContainerBuilder $container, $id, $firewall, &$authenticationProviders, $providerIds)
|
||||
{
|
||||
// Matcher
|
||||
$i = 0;
|
||||
$matcher = null;
|
||||
if (isset($firewall['request_matcher'])) {
|
||||
$matcher = new Reference($firewall['request_matcher']);
|
||||
|
@ -35,9 +35,7 @@ class RenderTokenParser extends \Twig_TokenParser
|
||||
// @deprecated in 2.2 and will be removed in 2.3
|
||||
if ($this->parser->getStream()->test(\Twig_Token::NAME_TYPE, 'with')) {
|
||||
$this->parser->getStream()->next();
|
||||
$attributes = $this->parser->getExpressionParser()->parseExpression();
|
||||
} else {
|
||||
$attributes = new \Twig_Node_Expression_Array(array(), $token->getLine());
|
||||
$this->parser->getExpressionParser()->parseExpression();
|
||||
}
|
||||
|
||||
// options
|
||||
|
@ -12,7 +12,6 @@
|
||||
namespace Symfony\Component\Form;
|
||||
|
||||
use Symfony\Component\Form\Exception\BadMethodCallException;
|
||||
use Symfony\Component\Form\Exception\Exception;
|
||||
use Symfony\Component\Form\Exception\UnexpectedTypeException;
|
||||
use Symfony\Component\PropertyAccess\PropertyPath;
|
||||
use Symfony\Component\PropertyAccess\PropertyPathInterface;
|
||||
|
@ -29,11 +29,6 @@ class MockFileSessionStorage extends MockArraySessionStorage
|
||||
*/
|
||||
private $savePath;
|
||||
|
||||
/**
|
||||
* @var array
|
||||
*/
|
||||
private $sessionData;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
|
@ -12,7 +12,6 @@
|
||||
namespace Symfony\Component\HttpKernel\DependencyInjection;
|
||||
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\HttpKernel\HttpKernelInterface;
|
||||
use Symfony\Component\HttpKernel\HttpKernel;
|
||||
use Symfony\Component\HttpKernel\Controller\ControllerResolverInterface;
|
||||
|
@ -11,7 +11,6 @@
|
||||
|
||||
namespace Symfony\Component\HttpKernel\EventListener;
|
||||
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\HttpKernel\HttpKernelInterface;
|
||||
use Symfony\Component\HttpKernel\Event\FilterResponseEvent;
|
||||
use Symfony\Component\HttpKernel\KernelEvents;
|
||||
|
@ -11,7 +11,6 @@
|
||||
|
||||
namespace Symfony\Component\HttpKernel\Fragment;
|
||||
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Symfony\Component\HttpFoundation\StreamedResponse;
|
||||
use Symfony\Component\HttpKernel\Controller\ControllerReference;
|
||||
|
@ -77,4 +77,4 @@ class HIncludeFragmentRendererTest extends \PHPUnit_Framework_TestCase
|
||||
$strategy = new HIncludeFragmentRenderer($engine);
|
||||
$this->assertEquals('<hx:include src="/foo">default</hx:include>', $strategy->render('/foo', Request::create('/'), array('default' => 'default'))->getContent());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -77,7 +77,7 @@ class StringUtil
|
||||
|
||||
// moves (move)
|
||||
array('sevom', 5, true, true, 'move'),
|
||||
|
||||
|
||||
// hooves (hoof), dwarves (dwarf), elves (elf), leaves (leaf)
|
||||
array('sev', 3, true, true, 'f'),
|
||||
|
||||
|
@ -151,7 +151,7 @@ class ApacheMatcherDumper extends MatcherDumper
|
||||
$allow[] = 'E=_ROUTING_allow_'.$method.':1';
|
||||
}
|
||||
|
||||
if ($hostRegex = $compiledRoute->getHostRegex()) {
|
||||
if ($compiledRoute->getHostRegex()) {
|
||||
$rule[] = sprintf("RewriteCond %%{ENV:__ROUTING_host_%s} =1", $hostRegexUnique);
|
||||
}
|
||||
|
||||
@ -162,8 +162,7 @@ class ApacheMatcherDumper extends MatcherDumper
|
||||
|
||||
// redirect with trailing slash appended
|
||||
if ($hasTrailingSlash) {
|
||||
|
||||
if ($hostRegex = $compiledRoute->getHostRegex()) {
|
||||
if ($compiledRoute->getHostRegex()) {
|
||||
$rule[] = sprintf("RewriteCond %%{ENV:__ROUTING_host_%s} =1", $hostRegexUnique);
|
||||
}
|
||||
|
||||
@ -173,7 +172,7 @@ class ApacheMatcherDumper extends MatcherDumper
|
||||
|
||||
// the main rule
|
||||
|
||||
if ($hostRegex = $compiledRoute->getHostRegex()) {
|
||||
if ($compiledRoute->getHostRegex()) {
|
||||
$rule[] = sprintf("RewriteCond %%{ENV:__ROUTING_host_%s} =1", $hostRegexUnique);
|
||||
}
|
||||
|
||||
|
@ -64,6 +64,7 @@ abstract class AbstractPreAuthenticatedListener implements ListenerInterface
|
||||
list($user, $credentials) = $this->getPreAuthenticatedData($request);
|
||||
} catch (BadCredentialsException $exception) {
|
||||
$this->clearToken();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -100,12 +100,15 @@ class MoFileLoader extends ArrayLoader implements LoaderInterface
|
||||
throw new InvalidResourceException("MO stream content has an invalid format.");
|
||||
}
|
||||
|
||||
$formatRevision = $this->readLong($stream, $isBigEndian);
|
||||
// formatRevision
|
||||
$this->readLong($stream, $isBigEndian);
|
||||
$count = $this->readLong($stream, $isBigEndian);
|
||||
$offsetId = $this->readLong($stream, $isBigEndian);
|
||||
$offsetTranslated = $this->readLong($stream, $isBigEndian);
|
||||
$sizeHashes = $this->readLong($stream, $isBigEndian);
|
||||
$offsetHashes = $this->readLong($stream, $isBigEndian);
|
||||
// sizeHashes
|
||||
$this->readLong($stream, $isBigEndian);
|
||||
// offsetHashes
|
||||
$this->readLong($stream, $isBigEndian);
|
||||
|
||||
$messages = array();
|
||||
|
||||
|
@ -414,7 +414,7 @@ class ExecutionContextTest extends \PHPUnit_Framework_TestCase
|
||||
|
||||
$this->assertEquals('bam.baz', $this->context->getPropertyPath('bam.baz'));
|
||||
}
|
||||
|
||||
|
||||
public function testGetPropertyPathWithNestedCollectionsMixed()
|
||||
{
|
||||
$constraints = new Collection(array(
|
||||
@ -424,13 +424,13 @@ class ExecutionContextTest extends \PHPUnit_Framework_TestCase
|
||||
)),
|
||||
'name' => new ConstraintA()
|
||||
));
|
||||
|
||||
|
||||
$visitor = new ValidationVisitor('Root', $this->metadataFactory, new ConstraintValidatorFactory(), $this->translator);
|
||||
$context = new ExecutionContext($visitor, $this->translator, self::TRANS_DOMAIN);
|
||||
$context->validateValue(array('foo' => array('foo' => 'VALID')), $constraints);
|
||||
$violations = $context->getViolations();
|
||||
|
||||
$this->assertEquals('[name]', $violations[1]->getPropertyPath());
|
||||
|
||||
$this->assertEquals('[name]', $violations[1]->getPropertyPath());
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -581,7 +581,7 @@ class GraphWalkerTest extends \PHPUnit_Framework_TestCase
|
||||
$violations = $this->walker->getViolations();
|
||||
$this->assertEquals('collection[foo][bar]', $violations[0]->getPropertyPath());
|
||||
}
|
||||
|
||||
|
||||
public function testWalkObjectUsesCorrectPropertyPathInViolationsWhenUsingNestedMixedCollections()
|
||||
{
|
||||
$constraint = new Collection(array(
|
||||
|
Reference in New Issue
Block a user