From: Florian Fainelli Date: Fri, 14 Apr 2006 14:44:54 +0000 (+0000) Subject: Remove the space when inserting the first element in a list. Closes #469 X-Git-Tag: whiterussian_rc6~272 X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=44842fd513d6cf4074b36e1981f1baeab6d788e8;p=openwrt%2Fsvn-archive%2Fopenwrt.git Remove the space when inserting the first element in a list. Closes #469 SVN-Revision: 3651 --- diff --git a/openwrt/package/webif/files/usr/lib/webif/webif.sh b/openwrt/package/webif/files/usr/lib/webif/webif.sh index cdf235889d..a81c245742 100644 --- a/openwrt/package/webif/files/usr/lib/webif/webif.sh +++ b/openwrt/package/webif/files/usr/lib/webif/webif.sh @@ -240,7 +240,11 @@ handle_list() { empty "$3" || { validate "${4:-none}|$2" && { - LISTVAL="$LISTVAL $2" + if empty "$LISTVAL"; then + LISTVAL="$2" + else + LISTVAL="$LISTVAL $2" + fi _changed=1 } }