var hasPalette = true; if(this.BITCOUNT_16bit == bitCount){ hasPalette = true; } if(this.BITCOUNT_24bit == bitCount){ hasPalette = true; } if(this.BITCOUNT_32bit == bitCount){ hasPalette = true; } True for all?