From 1aadb8c990a4a704223ba898e87d109735bad4f1 Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Mon, 1 Nov 2010 01:28:53 +0000 Subject: [PATCH] MINOR Using SecurityToken in ViewableData->getSecurityID() git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@113274 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- core/ViewableData.php | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/core/ViewableData.php b/core/ViewableData.php index 96529173b..24529cf98 100755 --- a/core/ViewableData.php +++ b/core/ViewableData.php @@ -699,12 +699,8 @@ class ViewableData extends Object implements IteratorAggregate { * @return string */ public function getSecurityID() { - if(!$id = Session::get('SecurityID')) { - $id = rand(); - Session::set('SecurityID', $id); - } - - return $id; + $token = SecurityToken::inst(); + return $token->getValue(); } /**