Commit Graph

22833 Commits

Author SHA1 Message Date
Fabien Potencier
b6a8ed6bb6 minor #17604 [2.7] [2.8] [3.0] [minor fix] remove duplicated value (HeahDude)
This PR was merged into the 2.7 branch.

Discussion
----------

[2.7] [2.8] [3.0] [minor fix] remove duplicated value

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | -

Commits
-------

d15c34a remove duplicated value
2016-01-29 18:33:07 +01:00
Jules Pietri
d15c34a51f remove duplicated value 2016-01-29 17:58:49 +01:00
Fabien Potencier
528572b764 minor #17565 [DependencyInjection] simplify the BC layer (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[DependencyInjection] simplify the BC layer

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

The change to the `setFactoryService()` method is consistent with what
we did with the `getFactoryService()` before (and how we handle the
deprecation of strict references in Symfony 2.8).

Commits
-------

6cd5ee3 [DependencyInjection] simplify the BC layer
2016-01-27 16:32:31 +01:00
Fabien Potencier
2ef46b311b minor #17566 Change couple of occurences of a public setUp() method to protected (jakzal)
This PR was merged into the 2.7 branch.

Discussion
----------

Change couple of occurences of a public setUp() method to protected

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

`setUp()` is a protected method. There's no occurrences on the 2.3 branch.

Commits
-------

5fe7359 Change couple of occurences of a public setUp() method to protected
2016-01-27 16:22:58 +01:00
Christian Flothmann
6cd5ee3b26 [DependencyInjection] simplify the BC layer
The change to the `setFactoryService()` method is consistent with what
we did with the `getFactoryService()` before (and how we handle the
deprecation of strict references in Symfony 2.8).
2016-01-27 12:47:27 +01:00
Jakub Zalas
5fe7359659 Change couple of occurences of a public setUp() method to protected 2016-01-27 11:47:13 +00:00
Christian Flothmann
3a027badb7 Merge branch '2.3' into 2.7
* 2.3:
  fixed CS
  [BrowserKit] Corrected HTTP_HOST logic #15398
  resolve aliases in factory services
  Remove invalid CSS white-space value
  Fix FileSystem tests on Windows
2016-01-27 12:27:15 +01:00
Fabien Potencier
828fba4e1d fixed CS 2016-01-27 11:46:45 +01:00
Fabien Potencier
7365bc0e84 bug #16265 [BrowserKit] Corrected HTTP_HOST logic (Naktibalda)
This PR was submitted for the master branch but it was merged into the 2.3 branch instead (closes #16265).

Discussion
----------

[BrowserKit] Corrected HTTP_HOST logic

HTTP_HOST is just a header - it does not override URI,
uri does not override HTTP_HOST header.
If HTTP_HOST is not set then and only then hostname is extracted from uri.

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | yes
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #15398
| License       | MIT
| Doc PR        |

Commits
-------

b5f524d [BrowserKit] Corrected HTTP_HOST logic #15398
2016-01-27 11:45:57 +01:00
Gintautas Miselis
b5f524d40b [BrowserKit] Corrected HTTP_HOST logic #15398 2016-01-27 11:45:57 +01:00
Fabien Potencier
72fa3bdda9 minor #17552 Remove invalid CSS white-space value (Triiistan)
This PR was merged into the 2.3 branch.

Discussion
----------

Remove invalid CSS white-space value

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Commits
-------

03d3182 Remove invalid CSS white-space value
2016-01-27 11:20:13 +01:00
Fabien Potencier
da16d15f13 bug #17554 [DependencyInjection] resolve aliases in factories (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[DependencyInjection] resolve aliases in factories

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | FriendsOfSymfony/FOSUserBundle#2048
| License       | MIT
| Doc PR        |

Commits
-------

fde10e7 resolve aliases in factories
2016-01-27 11:13:36 +01:00
Fabien Potencier
7743eefe18 bug #17555 [DependencyInjection] resolve aliases in factory services (xabbuh)
This PR was merged into the 2.3 branch.

Discussion
----------

[DependencyInjection] resolve aliases in factory services

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Commits
-------

7702189 resolve aliases in factory services
2016-01-27 11:10:53 +01:00
Christian Flothmann
fde10e799a resolve aliases in factories 2016-01-27 10:00:40 +01:00
Fabien Potencier
8967076e50 bug #17511 [Form] ArrayChoiceList can now deal with a null in choices (issei-m)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form] ArrayChoiceList can now deal with a null in choices

re-create for mistaken #17502

---

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Documentation says, since 2.7, choice value is treated as corresponding item value (if `choices_as_values` option is true). Null as well.

```php
$builder->add('attending', 'choice', array(
    'choices' => array(
        'yes' => true,
        'no' => false,
        'maybe' => null,
    ),
    'choices_as_values' => true,
));
```

But actually null doesn't work as expected since `ArrayChoiceList::getChoicesForValues()` uses `isset` to check whether given value exists in its choices.

It should use `array_key_exists` instead to do so here.

Commits
-------

68292bb [Form] ArrayChoiceList can now deal with a null in choices
2016-01-27 08:59:57 +01:00
Christian Flothmann
7702189cb4 resolve aliases in factory services 2016-01-27 08:57:17 +01:00
Fabien Potencier
025f761798 minor #16986 Fix Filesystem tests on Windows (WouterJ)
This PR was merged into the 2.3 branch.

Discussion
----------

Fix Filesystem tests on Windows

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #16985
| License       | MIT
| Doc PR        | -

PHP's symlink function doesn't support relative symlinks on Windows. Running the filesystem tests in Windows resulted in 2 erroring tests because of this. After this PR, these tests are skipped on Windows.

The error wasn't catched by appveyor, as appveyor doesn't support symlinks at all.

Commits
-------

c376cf3 Fix FileSystem tests on Windows
2016-01-27 08:39:45 +01:00
Fabien Potencier
1876b4f1c8 Merge branch '2.3' into 2.7
* 2.3:
  Static code analysis
  Update AnnotationDirectoryLoader.php
  [FrameworkBundle] Fix template location for PHP templates
  [FrameworkBundle] Add path verification to the template parsing test cases
2016-01-27 06:09:39 +01:00
Fabien Potencier
89e86197c1 minor #17480 Static code analysis (Koc)
This PR was merged into the 2.3 branch.

Discussion
----------

Static code analysis

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Things that done:
* fix case in method calls
* removed unused imports
* use shorter concat where it possible
* optimize some css
* removed duplicated array keys
* removed redurant return statements
* removed one-time variables
* do not pass arguments that not used in functions

Commits
-------

8db691a Static code analysis
2016-01-27 05:57:57 +01:00
Tristan Roussel
03d3182129 Remove invalid CSS white-space value 2016-01-27 01:14:25 +01:00
Fabien Potencier
96eb903c14 minor #17538 Increase the inlining YAML level for config:debug (javiereguiluz)
This PR was submitted for the master branch but it was merged into the 2.7 branch instead (closes #17538).

Discussion
----------

Increase the inlining YAML level for config:debug

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #16882
| License       | MIT
| Doc PR        | -

### Before

![debug_before](https://cloud.githubusercontent.com/assets/73419/12575512/52862d3c-c40d-11e5-9bc9-45e24c14b6e2.png)

### After

![debug_after](https://cloud.githubusercontent.com/assets/73419/12575515/5607b868-c40d-11e5-9578-5f004e4ad8df.png)

The new `6` number is completely arbitrary. I chose it because it's the minimum level that makes all the default Symfony services look right. I'm open to better recommendations.

Commits
-------

37655be Increase the inlining YAML level for config:debug
2016-01-26 16:21:42 +01:00
Javier Eguiluz
37655be008 Increase the inlining YAML level for config:debug 2016-01-26 16:21:36 +01:00
Fabien Potencier
55a79cb0fe minor #17429 [Serializer] Minor: fix CS and PHPDoc (dunglas)
This PR was squashed before being merged into the 2.7 branch (closes #17429).

Discussion
----------

[Serializer] Minor: fix CS and PHPDoc

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Commits
-------

ff568dc [Serializer] Minor: fix CS and PHPDoc
2016-01-26 13:15:52 +01:00
Kévin Dunglas
ff568dc518 [Serializer] Minor: fix CS and PHPDoc 2016-01-26 13:15:44 +01:00
WouterJ
c376cf3e06 Fix FileSystem tests on Windows 2016-01-26 10:09:52 +01:00
Fabien Potencier
234011d776 minor #17536 [Form] fix tests (xabbuh)
This PR was merged into the 2.7 branch.

Discussion
----------

[Form] fix tests

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Commits
-------

e791fa0 [Form] fix tests
2016-01-26 08:31:01 +01:00
Christian Flothmann
e791fa0405 [Form] fix tests 2016-01-26 08:10:13 +01:00
Fabien Potencier
7e000a0351 minor #17533 [Debug] Tell that the extension is for PHP 5 only (nicolas-grekas)
This PR was merged into the 2.7 branch.

Discussion
----------

[Debug] Tell that the extension is for PHP 5 only

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Commits
-------

1285a0d [Debug] Tell that the extension is for PHP 5 only
2016-01-26 07:58:29 +01:00
Fabien Potencier
c435c2f6c6 bug #17430 [Serializer] Ensure that groups are strings (dunglas)
This PR was squashed before being merged into the 2.7 branch (closes #17430).

Discussion
----------

[Serializer] Ensure that groups are strings

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | n/a
| License       | MIT
| Doc PR        | n/a

Commits
-------

0a3b877 [Serializer] Ensure that groups are strings
2016-01-26 07:57:14 +01:00
Kévin Dunglas
0a3b87701c [Serializer] Ensure that groups are strings 2016-01-26 07:57:11 +01:00
Nicolas Grekas
1285a0d637 [Debug] Tell that the extension is for PHP 5 only 2016-01-26 00:34:19 +01:00
Fabien Potencier
40035327b2 bug #15272 [FrameworkBundle] Fix template location for PHP templates (jakzal)
This PR was merged into the 2.3 branch.

Discussion
----------

[FrameworkBundle] Fix template location for PHP templates

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #14804
| License       | MIT
| Doc PR        | -

- [x] improve the test to cover logical path & filesystem path
- [x] Add a new test case and fix the path to the template

As the first commit only enchanced the test, and the second commit fixed the bug, it's best to review them seperately.

Commits
-------

132a4e4 [FrameworkBundle] Fix template location for PHP templates
cd42e2d [FrameworkBundle] Add path verification to the template parsing test cases
2016-01-25 18:08:12 +01:00
Konstantin.Myakshin
8db691ab94 Static code analysis 2016-01-25 19:00:36 +02:00
Fabien Potencier
a0a97d7521 bug #11232 [Routing] Fixes fatal errors with object resources in AnnotationDirectoryLoader::supports (Tischoi)
This PR was submitted for the master branch but it was merged into the 2.3 branch instead (closes #11232).

Discussion
----------

[Routing] Fixes fatal errors with object resources in AnnotationDirectoryLoader::supports

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

Fixes fatal errors that occur in the supports method with objects that aren't string convertible / don't implement ArrayAccess. This is mostly a problem because some locators try to access a specific character in the resource name.
Since the resource is checked if it's a string either way, it's the most simple solution to just move that check a bit ahead.

Commits
-------

5e80585 Update AnnotationDirectoryLoader.php
2016-01-25 17:58:14 +01:00
Tischoi
5e805850cc Update AnnotationDirectoryLoader.php 2016-01-25 17:58:14 +01:00
Fabien Potencier
193d5c8dd5 added a test 2016-01-25 17:36:36 +01:00
Fabien Potencier
7921e476c3 Merge branch '2.3' into 2.7
* 2.3:
  Escape the delimiter in Glob::toRegex
2016-01-25 17:36:11 +01:00
Fabien Potencier
ff4b815fdf bug #17526 Escape the delimiter in Glob::toRegex (javiereguiluz)
This PR was submitted for the 2.7 branch but it was merged into the 2.3 branch instead (closes #17526).

Discussion
----------

Escape the delimiter in Glob::toRegex

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #13531
| License       | MIT
| Doc PR        | -

Commits
-------

2c45f46 Escape the delimiter in Glob::toRegex
2016-01-25 17:35:29 +01:00
Javier Eguiluz
2c45f461c2 Escape the delimiter in Glob::toRegex 2016-01-25 17:35:23 +01:00
Fabien Potencier
ce0946dde0 Merge branch '2.3' into 2.7
* 2.3:
  fixed undefined variable
  Fixed the phpDoc of UserInterface
  fixed APCu dep version
  Added support for the `0.0.0.0/0` trusted proxy
  [DoctrineBridge][Validator] >= 2.3 Pass association instead of ID as argument
  [HttpKernel] Lookup the response even if the lock was released after 2 seconds
2016-01-25 17:27:59 +01:00
Fabien Potencier
ca96e334b4 bug #17527 fixed undefined variable (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

fixed undefined variable

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #16653
| License       | MIT
| Doc PR        | n/a

Commits
-------

4b21351 fixed undefined variable
2016-01-25 17:23:42 +01:00
Fabien Potencier
1d3fc10bca minor #17525 Fixed the phpDoc of UserInterface (javiereguiluz)
This PR was merged into the 2.3 branch.

Discussion
----------

Fixed the phpDoc of UserInterface

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #13037
| License       | MIT
| Doc PR        | -

#13037 is the original issue ... which was tried to be fixed in #13146 ... which was closed without merging it.

Commits
-------

8e2a33e Fixed the phpDoc of UserInterface
2016-01-25 17:22:59 +01:00
Fabien Potencier
4b21351f36 fixed undefined variable 2016-01-25 17:19:48 +01:00
Javier Eguiluz
8e2a33ec2d Fixed the phpDoc of UserInterface 2016-01-25 16:23:13 +01:00
Tobias Schultze
d9f02fb9b7 minor #17524 fixed APCu dep version (fabpot)
This PR was merged into the 2.3 branch.

Discussion
----------

fixed APCu dep version

 Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #17428
| License       | MIT

Commits
-------

3b7f4c7 fixed APCu dep version
2016-01-25 15:51:35 +01:00
Fabien Potencier
3b7f4c7050 fixed APCu dep version 2016-01-25 15:47:02 +01:00
Fabien Potencier
81ab4ee008 minor #17521 make apc class loader testable against apcu without apc bc layer (Tobion)
This PR was merged into the 2.7 branch.

Discussion
----------

make apc class loader testable against apcu without apc bc layer

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | -
| License       | MIT
| Doc PR        | -

Commits
-------

24160b3 make apc class loader testable against apcu without apc bc layer
2016-01-25 14:21:14 +01:00
Tobias Schultze
24160b3a2f make apc class loader testable against apcu without apc bc layer 2016-01-25 14:16:04 +01:00
Fabien Potencier
81605dd7c9 bug #15706 [framework-bundle] Added support for the 0.0.0.0/0 trusted proxy (zerkms)
This PR was submitted for the 2.8 branch but it was merged into the 2.3 branch instead (closes #15706).

Discussion
----------

[framework-bundle] Added support for the `0.0.0.0/0` trusted proxy

| Q             | A
| ------------- | ---
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| License       | MIT

It is relevant to my other PR: https://github.com/symfony/symfony/pull/14690

The original intention was to start accepting `0.0.0.0/0` as a trusted proxy (which is a valid CIDR notation).

The prupose is to allow all requests to be treated as trusted and to eliminate using dirty `['0.0.0.0/1', '128.0.0.0/1']` workaround.

Commits
-------

3188e1b Added support for the `0.0.0.0/0` trusted proxy
2016-01-25 13:36:48 +01:00
Ivan Kurnosov
3188e1b5d2 Added support for the 0.0.0.0/0 trusted proxy 2016-01-25 13:36:47 +01:00