From 8545d5fc10207dd36671a1d411cefd97e70b312f Mon Sep 17 00:00:00 2001 From: Bugra Firat Date: Fri, 5 Jun 2015 12:45:41 -0700 Subject: [PATCH] =?UTF-8?q?fix=20unintended=20side=20effects=20from=20PR-#?= =?UTF-8?q?9.=20remove=20class=20=E2=80=9Csv-visibility-hidden=E2=80=9D=20?= =?UTF-8?q?regardless=20of=20whether=20a=20move=20is=20executed,=20as=20th?= =?UTF-8?q?is=20class=20gets=20added=20on=20click=20and=20not=20on=20move.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/angular-sortable-view.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/angular-sortable-view.js b/src/angular-sortable-view.js index 808fe40..db2379b 100644 --- a/src/angular-sortable-view.js +++ b/src/angular-sortable-view.js @@ -458,10 +458,10 @@ html.off('mousemove touchmove', onMousemove); html.off('mouseup touchend', mouseup); html.removeClass('sv-sorting-in-progress'); - if(moveExecuted) + if(moveExecuted){ $controllers[0].$drop($scope.$index, opts); - else - $element.removeClass('sv-visibility-hidden'); + } + $element.removeClass('sv-visibility-hidden'); }); // onMousemove(e);