diff --git a/plugins/ExtendedProfile/js/profiledetail.js b/plugins/ExtendedProfile/js/profiledetail.js index 7960cee83f..f475046385 100644 --- a/plugins/ExtendedProfile/js/profiledetail.js +++ b/plugins/ExtendedProfile/js/profiledetail.js @@ -68,19 +68,17 @@ SN_EXTENDED.removeRow = function() { var div = $(this).closest('div'); var id = $(div).attr('id'); var cls = $(div).attr('class'); - var cnt = SN_EXTENDED.rowCount(cls); - var that = this; $("#confirm-dialog").dialog({ buttons : { "Confirm" : function() { + $(this).dialog("close"); var target = $(that).closest('tr'); target.fadeOut("slow", function() { - $(that).remove(); + $(target).remove(); + SN_EXTENDED.reorder(cls); }); - SN_EXTENDED.reorder(cls); - $(this).dialog("close"); }, "Cancel" : function() { $(this).dialog("close"); @@ -88,6 +86,8 @@ SN_EXTENDED.removeRow = function() { } }); + var cnt = SN_EXTENDED.rowCount(cls); + if (cnt > 1) { $("#confirm-dialog").dialog("open"); } diff --git a/plugins/ExtendedProfile/profiledetailsettingsaction.php b/plugins/ExtendedProfile/profiledetailsettingsaction.php index b0590f7316..01a8fa9c7b 100644 --- a/plugins/ExtendedProfile/profiledetailsettingsaction.php +++ b/plugins/ExtendedProfile/profiledetailsettingsaction.php @@ -60,7 +60,7 @@ class ProfileDetailSettingsAction extends ProfileSettingsAction // CSRF protection $token = $this->trimmed('token'); if (!$token || $token != common_session_token()) { - $this->show_form( + $this->showForm( _m( 'There was a problem with your session token. ' . 'Try again, please.'