* @return type?
*/
function setup() {
- global $SESSION;
if (empty($this->columns) || empty($this->uniqueid)) {
return false;
* Initialise table preferences.
*/
protected function initialise_table_preferences(): void {
+ global $SESSION;
// Load any existing user preferences.
if ($this->persistent) {
* @param array $oldprefs Old preferences to compare against.
*/
protected function save_preferences($oldprefs): void {
+ global $SESSION;
+
if ($this->prefs != $oldprefs) {
if ($this->persistent) {
set_user_preference('flextable_' . $this->uniqueid, json_encode($this->prefs));