Remove deprecated security token methods on Form

Use SecurityToken class directly instead
This commit is contained in:
Sean Harvey 2012-11-15 11:41:07 +13:00
parent 63820130c2
commit b43b023c1e

View File

@ -1295,34 +1295,6 @@ class Form extends RequestHandler {
return $this;
}
/**
* Disable security tokens for every form.
* Note that this doesn't apply to {@link SecurityToken}
* instances outside of the Form class, nor applies
* to existing form instances.
*
* See {@link enable_all_security_tokens()}.
*
* @deprecated 2.5 Use SecurityToken::disable()
*/
public static function disable_all_security_tokens() {
Deprecation::notice('2.5', 'Use SecurityToken::disable() instead.');
SecurityToken::disable();
}
/**
* Returns true if security is enabled - that is if the security token
* should be included and checked on this form.
*
* @deprecated 2.5 Use Form->getSecurityToken()->isEnabled()
*
* @return bool
*/
public function securityTokenEnabled() {
Deprecation::notice('2.5', 'Use Form->getSecurityToken()->isEnabled() instead.');
return $this->securityToken->isEnabled();
}
/**
* Returns the security token for this form (if any exists).
* Doesn't check for {@link securityTokenEnabled()}.