Skip to content

Commit

Permalink
[FrameworkBundle] added some service aliases to avoid some BC breaks
Browse files Browse the repository at this point in the history
  • Loading branch information
fabpot committed Feb 11, 2012
1 parent 93d81a1 commit 146a502
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
1 change: 0 additions & 1 deletion CHANGELOG-2.1.md
Expand Up @@ -40,7 +40,6 @@ To get the diff between two versions, go to https://github.com/symfony/symfony/c
* changed the default profiler storage to use the filesystem instead of SQLite
* added support for placeholders in route defaults and requirements (replaced by the value set in the service container)
* added Filesystem component as a dependency
* [BC BREAK] changed `session.xml` service name `session.storage.native` to `session.storage.native_file`
* added new session storage drivers to session.xml: `session.storage.native_memcache`, `session.storage.native_memcached`,
`session.storage.native_sqlite`, `session.storage.null`, `session.storage.memcache`,
and `session.storage.memcached`. Added `session.storage.mock_file` service for functional session testing.
Expand Down
Expand Up @@ -38,5 +38,9 @@
<tag name="kernel.event_subscriber" />
<argument type="service" id="service_container" />
</service>

<!-- for BC -->
<service id="session.storage.native" alias="session.storage.native_file" />
<service id="session.storage.filesystem" alias="session.storage.mock_file" />
</services>
</container>
Expand Up @@ -46,19 +46,19 @@ public function get($name, $default = null)
return $this->session->get($name, $default);
}

public function getFlash($type, $default = null)
public function getFlash($name, $default = null)
{
return $this->session->getFlashes()->get($type);
return $this->session->getFlashes()->get($name);
}

public function getFlashes()
{
return $this->session->getFlashes()->all();
}

public function hasFlash($type)
public function hasFlash($name)
{
return $this->session->getFlashes()->has($type);
return $this->session->getFlashes()->has($name);
}

/**
Expand Down

0 comments on commit 146a502

Please sign in to comment.