* Fix wrong setting of sessionVar.

This commit is contained in:
Lufei
2023-11-03 08:39:36 +08:00
parent 4f6bfc8814
commit c52ef8b2f3
2 changed files with 5 additions and 3 deletions
+3 -3
View File
@@ -217,13 +217,13 @@ class misc extends control
* Show captcha and save to session.
*
* @param string $sessionVar
* @param string $uuid
* @access public
* @return void
*/
public function captcha($sessionVar = 'captcha', $uuid = '')
public function captcha($sessionVar = 'captcha')
{
if($sessionVar == 'user') die('The string user is not allowed to be defined as a session field.');
if(in_array(strtolower($sessionVar), $this->config->misc->disabledSessionVar)) die("The string {$sessionVar} is not allowed to be defined as a session field.");
$obLevel = ob_get_level();
for($i = 0; $i < $obLevel; $i++) ob_end_clean();