Skip to content
This repository has been archived by the owner on Jan 31, 2020. It is now read-only.

Commit

Permalink
Merge remote-tracking branch 'Maks3w/patch-2'
Browse files Browse the repository at this point in the history
  • Loading branch information
Showing 1 changed file with 3 additions and 13 deletions.
16 changes: 3 additions & 13 deletions src/Configuration/SessionConfiguration.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,27 +126,17 @@ public function getStorageOption($storageOption)
// No remote storage option; just return the current value
return $this->rememberMeSeconds;
case 'url_rewriter_tags':
$key = 'url_rewriter.tags';
break;
return ini_get('url_rewriter.tags');
// The following all need a transformation on the retrieved value;
// however they use the same key naming scheme
case 'use_cookies':
case 'use_only_cookies':
case 'use_trans_sid':
case 'cookie_httponly':
$transform = function ($value) {
return (bool) $value;
};
return (bool) ini_get('session.' . $storageOption);
default:
$key = 'session.' . $storageOption;
break;
}

$value = ini_get($key);
if (false !== $transform) {
$value = $transform($value);
return ini_get('session.' . $storageOption);
}
return $value;
}

/**
Expand Down

0 comments on commit 3723e41

Please sign in to comment.