From d87c6aaf87c6c652bd45b8a7c420d5e7b1112ede Mon Sep 17 00:00:00 2001 From: Nicola Galgano Date: Thu, 5 Mar 2015 20:37:14 +0100 Subject: [PATCH 1/3] PostgreSQL - sql error save category with tag #### Steps to reproduce the issue go to the category manager and create or edit a category In the tags field create or add a tag then click "Save". #### Expected result The category is saved with the tag #### Actual result the tag field is cleared and the category is not saved #### System information PostgreSQL 9.3.5 Joomla 3.4.0 #### Additional comments added a sanity check for NOT NULL FIELDS --- libraries/cms/table/corecontent.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/libraries/cms/table/corecontent.php b/libraries/cms/table/corecontent.php index 417ae011d0fd4..b32c5ef7e36b5 100644 --- a/libraries/cms/table/corecontent.php +++ b/libraries/cms/table/corecontent.php @@ -111,6 +111,15 @@ public function check() $this->core_alias = JFactory::getDate()->format('Y-m-d-H-i-s'); } + // Not Null sanity check + if (empty($this->core_images)) + { + $this->core_images = '{}'; + } + if (empty($this->core_urls)) + { + $this->core_urls = '{}'; + } // Check the publish down date is not earlier than publish up. if ($this->core_publish_down > $this->_db->getNullDate() && $this->core_publish_down < $this->core_publish_up) { From 1f5e40f6d14cbc0793dc42ce90a3d27ee3126551 Mon Sep 17 00:00:00 2001 From: Nicola Galgano Date: Thu, 5 Mar 2015 23:10:30 +0100 Subject: [PATCH 2/3] travis error tabs instead of spaces --- libraries/cms/table/corecontent.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libraries/cms/table/corecontent.php b/libraries/cms/table/corecontent.php index b32c5ef7e36b5..229ad0e305a07 100644 --- a/libraries/cms/table/corecontent.php +++ b/libraries/cms/table/corecontent.php @@ -110,8 +110,8 @@ public function check() { $this->core_alias = JFactory::getDate()->format('Y-m-d-H-i-s'); } - - // Not Null sanity check + + // Not Null sanity check if (empty($this->core_images)) { $this->core_images = '{}'; From 7e518ea5adc8d4656dd0d3ee21a64fc99bfb2b12 Mon Sep 17 00:00:00 2001 From: Nicola Galgano Date: Thu, 5 Mar 2015 23:34:47 +0100 Subject: [PATCH 3/3] whitespace whitespace removed --- libraries/cms/table/corecontent.php | 1 - 1 file changed, 1 deletion(-) diff --git a/libraries/cms/table/corecontent.php b/libraries/cms/table/corecontent.php index 229ad0e305a07..5bf83679a9e3d 100644 --- a/libraries/cms/table/corecontent.php +++ b/libraries/cms/table/corecontent.php @@ -110,7 +110,6 @@ public function check() { $this->core_alias = JFactory::getDate()->format('Y-m-d-H-i-s'); } - // Not Null sanity check if (empty($this->core_images)) {