From 45a14f4fbb8f1bf73d66a5f54e92067bb01d40f0 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Tue, 16 Oct 2012 19:13:28 +0000 Subject: [PATCH] Fix status labels showing as serialized when editing them --- timesheet/inc/class.timesheet_bo.inc.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/timesheet/inc/class.timesheet_bo.inc.php b/timesheet/inc/class.timesheet_bo.inc.php index 24954a7eb4..13028be67d 100644 --- a/timesheet/inc/class.timesheet_bo.inc.php +++ b/timesheet/inc/class.timesheet_bo.inc.php @@ -172,7 +172,11 @@ class timesheet_bo extends so_sql_cf protected function load_statuses() { $this->status_labels =& $this->config_data['status_labels']; - if (!is_array($this->status_labels)) $this->status_labels= array($this->status_labels); + if (!is_array($this->status_labels)) + { + $this->status_labels = (@unserialize($this->status_labels) === false) ? + array($this->status_labels) : @unserialize($this->status_labels); + } foreach ($this->status_labels as $status_id => $label) {