From e24639d9d0296ce16b33682e9d66f3cd1d5bef07 Mon Sep 17 00:00:00 2001
From: Olav Morken <olav.morken@uninett.no>
Date: Thu, 15 May 2008 14:10:53 +0000
Subject: [PATCH] Session: Remove uses of SimpleSAML_Session::init(...).

git-svn-id: https://simplesamlphp.googlecode.com/svn/trunk@566 44740490-163a-0410-bde0-09ae8108e29a
---
 lib/SimpleSAML/XML/SAML20/AuthnResponse.php | 4 ++--
 lib/SimpleSAML/XML/Shib13/AuthnResponse.php | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/SimpleSAML/XML/SAML20/AuthnResponse.php b/lib/SimpleSAML/XML/SAML20/AuthnResponse.php
index 7ac0a60aa..5bc4e0520 100644
--- a/lib/SimpleSAML/XML/SAML20/AuthnResponse.php
+++ b/lib/SimpleSAML/XML/SAML20/AuthnResponse.php
@@ -509,8 +509,8 @@ class SimpleSAML_XML_SAML20_AuthnResponse extends SimpleSAML_XML_AuthnResponse {
 			}
 	
 			/* Update the session information */
-			SimpleSAML_Session::init(true, 'saml2');
 			$session = SimpleSAML_Session::getInstance();
+			$session->doLogin('saml2');
 	
 			$session->setAttributes($this->attributes);
 			$session->setNameID($this->nameid);
@@ -519,8 +519,8 @@ class SimpleSAML_XML_SAML20_AuthnResponse extends SimpleSAML_XML_AuthnResponse {
 		} elseif ($status == 'urn:oasis:names:tc:SAML:2.0:status:NoPassive') {
 			/* 	Do not process the authResponse when NoPassive is sent - we continue with an empty set of attributes.
 		   		Some day we will be able to tell the application what happened */
-			SimpleSAML_Session::init(true, 'saml2');
 			$session = SimpleSAML_Session::getInstance();
+			$session->doLogin('saml2');
 			$session->setAttributes(array());
 		} else {
 			SimpleSAML_Utilities::fatalError($session->getTrackID(), 'RESPONSESTATUSNOSUCCESS', new Exception("Status = " . $status));
diff --git a/lib/SimpleSAML/XML/Shib13/AuthnResponse.php b/lib/SimpleSAML/XML/Shib13/AuthnResponse.php
index 05ffe1cbe..c3f103f2e 100644
--- a/lib/SimpleSAML/XML/Shib13/AuthnResponse.php
+++ b/lib/SimpleSAML/XML/Shib13/AuthnResponse.php
@@ -115,8 +115,8 @@ class SimpleSAML_XML_Shib13_AuthnResponse extends SimpleSAML_XML_AuthnResponse {
 
 	public function createSession() {
 	
-		SimpleSAML_Session::init(true, 'shib13');
 		$session = SimpleSAML_Session::getInstance();
+		$session->doLogin('shib13');
 		$session->setAttributes($this->getAttributes());
 		
 		$nameid = $this->getNameID();
-- 
GitLab