Stricter linting fixes part 1

This commit is contained in:
Mark Salsbery 2020-06-30 10:25:38 -07:00
parent 4492bdd6d8
commit f20b7e738c
2 changed files with 3 additions and 5 deletions

View File

@ -654,8 +654,7 @@ function processResponse( xhr ){
} catch (e){
data = xhr.responseText;
}
/* eslint-disable no-useless-escape */
}else if( responseText.match(/\s*[\{\[].*/) ){
}else if( responseText.match(/\s*[{[].*/) ){
try{
data = $.parseJSON(responseText);
} catch(e){

View File

@ -2288,8 +2288,7 @@ function getTileSourceImplementation( viewer, tileSource, imgOptions, successCal
if ( tileSource.match( /^\s*<.*>\s*$/ ) ) {
tileSource = $.parseXml( tileSource );
//json should start with "{" or "[" and end with "}" or "]"
/* eslint-disable no-useless-escape */
} else if ( tileSource.match(/^\s*[\{\[].*[\}\]]\s*$/ ) ) {
} else if ( tileSource.match(/^\s*[{[].*[}\]]\s*$/ ) ) {
try {
var tileSourceJ = $.parseJSON(tileSource);
tileSource = tileSourceJ;
@ -3195,7 +3194,7 @@ function onCanvasScroll( event ) {
}
}
return true;
return undefined;
}
function onContainerEnter( event ) {