Double negate state.garrisonHolder
Differential Revision: https://code.wildfiregames.com/D1326 Reviewed by: mimo This was SVN commit r21355.
This commit is contained in:
parent
7541291621
commit
79090bfa63
@ -370,7 +370,7 @@ function unloadTemplate(template, owner)
|
||||
// Filter out all entities that aren't garrisonable.
|
||||
"garrisonHolders": g_Selection.toList().filter(ent => {
|
||||
let state = GetEntityState(ent);
|
||||
return state && state.garrisonHolder;
|
||||
return state && !!state.garrisonHolder;
|
||||
})
|
||||
});
|
||||
}
|
||||
@ -404,7 +404,7 @@ function unloadAll()
|
||||
{
|
||||
let garrisonHolders = g_Selection.toList().filter(e => {
|
||||
let state = GetEntityState(e);
|
||||
return state && state.garrisonHolder;
|
||||
return state && !!state.garrisonHolder;
|
||||
});
|
||||
|
||||
if (!garrisonHolders.length)
|
||||
|
Loading…
Reference in New Issue
Block a user