Fixed deprecations

This commit is contained in:
Ingo Schommer 2013-03-19 10:38:14 +01:00
parent 3932241844
commit b416e50bff
2 changed files with 10 additions and 6 deletions

View File

@ -330,7 +330,7 @@ class Member extends DataObject implements TemplateGlobalProvider {
} else { } else {
$this->RememberLoginToken = null; $this->RememberLoginToken = null;
Cookie::set('alc_enc', null); Cookie::set('alc_enc', null);
Cookie::forceExpiry('alc_enc'); Cookie::force_expiry('alc_enc');
} }
// Clear the incorrect log-in count // Clear the incorrect log-in count

View File

@ -177,19 +177,23 @@ class DataExtensionTest_Player extends DataObject implements TestOnly {
class DataExtensionTest_PlayerExtension extends DataExtension implements TestOnly { class DataExtensionTest_PlayerExtension extends DataExtension implements TestOnly {
public static function add_to_class($class = null, $extensionClass = null, $args = null) { public static function get_extra_config($class = null, $extensionClass = null, $args = null) {
$config = array();
// Only add these extensions if the $class is set to DataExtensionTest_Player, to // Only add these extensions if the $class is set to DataExtensionTest_Player, to
// test that the argument works. // test that the argument works.
if($class == 'DataExtensionTest_Player') { if($class == 'DataExtensionTest_Player') {
Config::inst()->update($class, 'db', array( $config['db'] = array(
'Address' => 'Text', 'Address' => 'Text',
'DateBirth' => 'Date', 'DateBirth' => 'Date',
'Status' => "Enum('Shooter,Goalie')" 'Status' => "Enum('Shooter,Goalie')"
)); );
Config::inst()->update($class, 'defaults', array( $config['defaults'] = array(
'Status' => 'Goalie' 'Status' => 'Goalie'
)); );
} }
return $config;
} }
} }