From aea080d6bdfcf1541d7481477433307d3a514779 Mon Sep 17 00:00:00 2001 From: objecttothis <17935339+objecttothis@users.noreply.github.com> Date: Tue, 26 Feb 2019 14:08:33 +0400 Subject: [PATCH] Update Attribute.php Without this else, TEXT->DROPDOWN fails. It just returns a simple success because no database changes are needed other than changing the definition_type which is not done here. This would also cause all other conversions not listed to automatically succeed, but we don't need to worry because those are restricted in the view to only ones that are actually supported. --- application/models/Attribute.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/application/models/Attribute.php b/application/models/Attribute.php index 7b4b329bd..aa8ed0342 100644 --- a/application/models/Attribute.php +++ b/application/models/Attribute.php @@ -303,6 +303,12 @@ class Attribute extends CI_Model $this->db->trans_complete(); } + //Any other allowed conversion does not get checked here + else + { + $success = TRUE; + } + return $success; } @@ -542,4 +548,4 @@ class Attribute extends CI_Model return $this->db->update('attribute_definitions', array('deleted' => 1)); } -} \ No newline at end of file +}