CanvasPool parent checks are now falsey, not just !== null.

This commit is contained in:
Richard Davey 2016-07-06 20:59:42 +01:00
parent 33150018ad
commit 8a3c71f050

View file

@ -68,7 +68,7 @@ PIXI.CanvasPool = {
for (var i = 0; i < pool.length; i++)
{
if (pool[i].parent === null)
if (!pool[i].parent)
{
return i;
}
@ -134,7 +134,7 @@ PIXI.CanvasPool = {
for (var i = 0; i < pool.length; i++)
{
if (pool[i].parent !== null)
if (pool[i].parent)
{
c++;
}
@ -158,7 +158,7 @@ PIXI.CanvasPool = {
for (var i = 0; i < pool.length; i++)
{
if (pool[i].parent === null)
if (!pool[i].parent)
{
c++;
}