Skip to content

Commit d0de3a4

Browse files
committed
PHP <5.4 comaptibility fix for #25
1 parent f251930 commit d0de3a4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Middleware/CsrfGuard.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public function check() {
5757
// Create token
5858
$env = $this->app->environment();
5959

60-
if ( PHP_SESSION_ACTIVE === session_status() ){
60+
if ( "" === session_id() ){
6161
if ( ! isset( $_SESSION[ $this->key ] ) ){
6262
$_SESSION[ $this->key ] = sha1( serialize( $_SERVER ) . rand( 0, 0xffffffff ) );
6363
}

0 commit comments

Comments
 (0)