Clean JSHint errors except for already defined and configuration functions related errors

This commit is contained in:
Damien Corneau 2015-05-06 16:47:57 +09:00
parent ef6baa0bed
commit 9b249eab2c
4 changed files with 8 additions and 23 deletions

View file

@ -12,9 +12,10 @@
"newcap": true,
"noarg": true,
"quotmark": "single",
"shadow": "inner",
"regexp": true,
"undef": true,
"unused": true,
"unused": "vars",
"strict": true,
"trailing": true,
"smarttabs": true,

View file

@ -67,11 +67,7 @@ function getRestApiBase() {
if (port === 3333 || port === 9000) {
port = 8080;
}
return location.protocol+"//"+location.hostname+":"+port + skipTrailingSlash(location.pathname) + "/api";
}
function skipTrailingSlash(path) {
return path.slice(-1) === "/" ? path.substring(0, path.length-1) : path;
return location.protocol + '//' + location.hostname + ':' + port + '/api';
}
/**
@ -102,7 +98,9 @@ angular
])
.filter('breakFilter', function() {
return function (text) {
if (text !== undefined) return text.replace(/\n/g, '<br />');
if (text !== undefined) {
return text.replace(/\n/g, '<br />');
}
};
})
.config(function ($routeProvider, WebSocketProvider) {

View file

@ -1,4 +1,4 @@
/* global confirm:false, alert:false */
/* global confirm:false, alert:false, getRestApiBase:false */
/* jshint loopfunc: true */
/*
* Licensed under the Apache License, Version 2.0 (the "License");
@ -266,7 +266,7 @@ angular.module('zeppelinWebApp').controller('InterpreterCtrl', function($scope,
for (var i=0; i < $scope.interpreterSettings.length; i++) {
var setting = $scope.interpreterSettings[i];
if (setting.id === settingId) {
delete $scope.interpreterSettings[i].properties[key]
delete $scope.interpreterSettings[i].properties[key];
break;
}
}

View file

@ -1,14 +0,0 @@
/*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
alert("moved to https://ajaxorg.github.io/ace-builds/demo/bookmarklet/index.html. Please update your bookmark")