Skip to content

Commit 7281c7c

Browse files
committed
Fix session check
1 parent e6aca1a commit 7281c7c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

lib/Opauth/Opauth.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -220,11 +220,11 @@ public function callback(){
220220
$response = null;
221221
switch($this->env['callback_transport']){
222222
case 'session':
223-
if (!isset($_SESSION)){
224-
session_start();
225-
}
226-
$response = $_SESSION['opauth'];
227-
unset($_SESSION['opauth']);
223+
if (!session_id()){
224+
session_start();
225+
$response = $_SESSION['opauth'];
226+
unset($_SESSION['opauth']);
227+
}
228228
break;
229229
case 'post':
230230
$response = unserialize(base64_decode( $_POST['opauth'] ));

0 commit comments

Comments
 (0)