mirror of
https://github.com/Radarr/Radarr.git
synced 2024-11-05 02:22:31 +01:00
Clean up jsHint warnings (#1225)
This commit is contained in:
parent
1b29b89bf1
commit
31fcac5bd9
@ -39,7 +39,7 @@ module.exports = Marionette.Layout.extend({
|
||||
RootFolderCollection.synced = true;
|
||||
});
|
||||
|
||||
if (options.action == "search") {
|
||||
if (options.action === "search") {
|
||||
this._addMovies(options);
|
||||
}
|
||||
},
|
||||
|
@ -49,7 +49,7 @@ module.exports = Marionette.Layout.extend({
|
||||
|
||||
this.throttledSearch = _.debounce(this.search, 1000, { trailing : true }).bind(this);
|
||||
|
||||
if (options.action == "search") {
|
||||
if (options.action === "search") {
|
||||
this.search({term: options.query});
|
||||
}
|
||||
|
||||
|
@ -315,8 +315,8 @@ module.exports = Marionette.Layout.extend({
|
||||
|
||||
//this._showToolbar();
|
||||
//debugger;
|
||||
self = this;
|
||||
setTimeout(function(){self._showToolbar();}, 0);//wtf???
|
||||
var self = this;
|
||||
setTimeout(function(){self._showToolbar();}, 0); // jshint ignore:line
|
||||
//this._renderView();
|
||||
},
|
||||
|
||||
|
@ -49,7 +49,7 @@ var filterModes = {
|
||||
"inCinemas",
|
||||
//function(model) { return model.getStatus() == "inCinemas"; }
|
||||
]
|
||||
}//Hacky, I know
|
||||
}; //Hacky, I know
|
||||
|
||||
|
||||
var Collection = PageableCollection.extend({
|
||||
@ -273,7 +273,7 @@ var filterMode = Config.getValue("series.filterMode", "all");
|
||||
var sortKey = Config.getValue("movie.sortKey", "sortTitle");
|
||||
var sortDir = Config.getValue("movie.sortDirection", -1);
|
||||
var sortD = "asc";
|
||||
if (sortDir == 1) {
|
||||
if (sortDir === 1) {
|
||||
sortD = "desc";
|
||||
}
|
||||
|
||||
|
@ -28,9 +28,9 @@ module.exports = NzbDroneController.extend({
|
||||
this._renderMovieDetails(query);
|
||||
//debugger;
|
||||
} else {
|
||||
self = this;
|
||||
var self = this;
|
||||
$.getJSON(window.NzbDrone.ApiRoot + '/movie/titleslug/'+query, { }, function(data) {
|
||||
FullMovieCollection.add(data)
|
||||
FullMovieCollection.add(data);
|
||||
self._renderMovieDetails(query);
|
||||
});
|
||||
this.listenTo(FullMovieCollection, 'sync', function(model, options) {
|
||||
|
@ -30,7 +30,7 @@ $.fn.bindSearch = function() {
|
||||
},
|
||||
templates : {
|
||||
empty : function(input) {
|
||||
return '<div class="tt-dataset-series"><span class="tt-suggestions" style="display: block;"><div class="tt-suggestion"><p style="white-space: normal;"><a class="no-movies-found" href="/addmovies/search/' + input.query + '">Search for "' + input.query + '"</a></p></div></span></div>'
|
||||
return '<div class="tt-dataset-series"><span class="tt-suggestions" style="display: block;"><div class="tt-suggestion"><p style="white-space: normal;"><a class="no-movies-found" href="/addmovies/search/' + input.query + '">Search for "' + input.query + '"</a></p></div></span></div>';
|
||||
},
|
||||
},
|
||||
source : substringMatcher()
|
||||
|
@ -32,7 +32,7 @@ var view = Marionette.ItemView.extend({
|
||||
var refresh=params.get('refresh');
|
||||
if (oauth && refresh){
|
||||
//var callback_url = window.location.href;
|
||||
history.pushState('object', 'title', (window.location.href).replace(window.location.search, ''));
|
||||
history.pushState('object', 'title', (window.location.href).replace(window.location.search, '')); // jshint ignore:line
|
||||
this.ui.authToken.val(oauth).trigger('change');
|
||||
this.ui.refreshToken.val(refresh).trigger('change');
|
||||
//Config.setValue("traktAuthToken", oauth);
|
||||
@ -101,7 +101,7 @@ var view = Marionette.ItemView.extend({
|
||||
//if (event.item.startsWith('tt')) {
|
||||
// newText = newText+'['+event.item+']';
|
||||
//}
|
||||
event.item = response['titleSlug'];//+' ('+response['year']+')-'+response['tmdbId'];
|
||||
event.item = response.titleSlug;//+' ('+response['year']+')-'+response['tmdbId'];
|
||||
});
|
||||
|
||||
promise.error(function(request, status, error) {
|
||||
|
Loading…
Reference in New Issue
Block a user