Skip to content

Commit e6e5c1e

Browse files
safety checks for session_start
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
1 parent c388363 commit e6e5c1e

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

prestashop8.x/tawkto.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,9 @@ private function installTab()
101101
*/
102102
public function hookDisplayFooter()
103103
{
104-
session_start();
104+
if (session_status() === PHP_SESSION_NONE && !headers_sent()) {
105+
session_start();
106+
}
105107

106108
$current_widget = self::getPropertyAndWidget();
107109
if (empty($current_widget)) {

0 commit comments

Comments
 (0)