mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
API Removed deprecated Session::set_config()
This commit is contained in:
parent
1d438d3fb5
commit
81e5c7ac40
@ -1283,6 +1283,7 @@ After (`mysite/_config/config.yml`):
|
||||
- `getModules`
|
||||
- `getConfigDirs`
|
||||
- `getConfigs`
|
||||
* Removed `Session::set_config()` and `Session::get_config()`. Use the `Session.timeout` config setting instead
|
||||
|
||||
#### <a name="overview-general-deprecated"></a>General and Core Deprecated API
|
||||
|
||||
@ -1817,4 +1818,4 @@ New `TimeField` methods replace `getConfig()` / `setConfig()`
|
||||
you will need to define this method and return a short name describing the login method.
|
||||
* `MemberLoginForm` has a new constructor argument for the authenticator class, athough tis is usually
|
||||
constructed by `MemberAuthenticator` and won't affect normal use.
|
||||
* `Authenticator` methods `register` and `unregister` are deprecated in favor of using `Config`
|
||||
* `Authenticator` methods `register` and `unregister` are deprecated in favor of using `Config`
|
||||
|
@ -544,26 +544,4 @@ class Session
|
||||
{
|
||||
self::current_session()->inst_destroy($removeCookie);
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the timeout of a Session value
|
||||
*
|
||||
* @deprecated 4.0 Use the "Session.timeout" config setting instead
|
||||
*
|
||||
* @param int $timeout Time until a session expires in seconds. Defaults to expire when browser is closed.
|
||||
*/
|
||||
public static function set_timeout($timeout)
|
||||
{
|
||||
Deprecation::notice('4.0', 'Use the "Session.timeout" config setting instead');
|
||||
Config::inst()->update('SilverStripe\\Control\\Session', 'timeout', (int) $timeout);
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated 4.0 Use the "Session.timeout" config setting instead
|
||||
*/
|
||||
public static function get_timeout()
|
||||
{
|
||||
Deprecation::notice('4.0', 'Use the "Session.timeout" config setting instead');
|
||||
return Config::inst()->get('SilverStripe\\Control\\Session', 'timeout');
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user