Disable no-eval rule only on the specified line

Signed-off-by: Maurício Meneghini Fauth <mauricio@fauth.dev>
This commit is contained in:
Maurício Meneghini Fauth 2019-05-29 19:27:48 -03:00
parent 3e11b7e6b3
commit 39bcd04878
2 changed files with 2 additions and 2 deletions

View File

@ -4141,7 +4141,7 @@ Functions.toggleButton = function ($obj) {
.animate({ 'left': operator + move + 'px' }, function () {
$container.removeClass('isActive');
});
/* eslint no-eval: "warn" */
// eslint-disable-next-line no-eval
eval(callback);
} else {
Functions.ajaxShowMessage(data.error, false);

View File

@ -251,7 +251,7 @@ AJAX.registerOnload('gis_data_editor.js', function () {
$('#placeholder').empty().removeClass('hasSVG').html(data.visualization);
$('#openlayersmap').empty();
/* TODO: the gis_data_editor should rather return JSON than JS code to eval */
/* eslint no-eval: "warn" */
// eslint-disable-next-line no-eval
eval(data.openLayers);
initGISEditorVisualization();
} else {