From 6fd841ebee16df442fdc751e4e55ed9814b3d3ba Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Thu, 17 Mar 2016 17:22:56 +0000 Subject: [PATCH] Don't return empty array for empty single selects, should fix some problems with empty selections --- etemplate/js/et2_widget_selectbox.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etemplate/js/et2_widget_selectbox.js b/etemplate/js/et2_widget_selectbox.js index 6826f91249..9ec5d36d6f 100644 --- a/etemplate/js/et2_widget_selectbox.js +++ b/etemplate/js/et2_widget_selectbox.js @@ -751,7 +751,7 @@ var et2_selectbox = (function(){ "use strict"; return et2_inputWidget.extend( else { this.value = this._super.apply(this, arguments); - if (this.value === null) this.value = []; // do NOT return null, as it does not get transmitted to server + if (this.value === null) this.value = this.options.multiple ? [] : ""; // do NOT return null, as it does not get transmitted to server } return this.value; },