From 980fbbea512dd25be499fdb2449f19445c420cc4 Mon Sep 17 00:00:00 2001 From: Paul Bakaus Date: Thu, 26 Jun 2008 10:00:32 +0000 Subject: [PATCH] sortable: fixed serialize issue when a key was specified as option, but no custom expression --- ui/ui.sortable.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/ui.sortable.js b/ui/ui.sortable.js index 4dc9479f9..87eda5c06 100644 --- a/ui/ui.sortable.js +++ b/ui/ui.sortable.js @@ -69,7 +69,7 @@ $.widget("ui.sortable", $.extend($.ui.mouse, { items.each(function() { var res = ($(this).attr(o.attribute || 'id') || '').match(o.expression || (/(.+)[-=_](.+)/)); - if(res) str.push((o.key || res[1])+'[]='+(o.key ? res[1] : res[2])); + if(res) str.push((o.key || res[1])+'[]='+(o.key && o.expression ? res[1] : res[2])); }); return str.join('&');