Correct error handling when editing variable fails

Issue #12317

Signed-off-by: Michal Čihař <michal@cihar.com>
This commit is contained in:
Michal Čihař 2016-06-13 12:46:29 +02:00
parent 2d7d2d2e8b
commit 0caecf5fc8

View File

@ -100,7 +100,11 @@ AJAX.registerOnload('server_variables.js', function () {
.data('content', data.variable);
PMA_ajaxRemoveMessage($msgbox);
} else {
PMA_ajaxShowMessage(data.error, false);
if (data.error == '') {
PMA_ajaxShowMessage(PMA_messages.strRequestFailed, false);
} else {
PMA_ajaxShowMessage(data.error, false);
}
$valueCell.html($valueCell.data('content'));
}
$cell.removeClass('edit').html($myEditLink);