forked from 0x2620/pandora
clipList: handle smart lists with no conditions (fixes #2884)
I have a smart list which has no conditions (ie matches all items). This breaks "View as Clips" when the list is selected because: pandora.api.getList({id: "wjt:Everything"}) -> { // ... data: { // ... query: {} } } so result.data.query.conditions is undefined.
This commit is contained in:
parent
8f1a0c3047
commit
e47c652ad0
1 changed files with 1 additions and 1 deletions
|
@ -85,7 +85,7 @@ pandora.ui.clipList = function(videoRatio) {
|
||||||
// add possible layer conditions from query
|
// add possible layer conditions from query
|
||||||
if (ui._list) {
|
if (ui._list) {
|
||||||
pandora.api.getList({id: ui._list}, function(result) {
|
pandora.api.getList({id: ui._list}, function(result) {
|
||||||
if (result.data.type == 'smart') {
|
if (result.data.type == 'smart' && result.data.query.conditions) {
|
||||||
addConditions(query, result.data.query.conditions);
|
addConditions(query, result.data.query.conditions);
|
||||||
query.operator = result.data.query.operator;
|
query.operator = result.data.query.operator;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue