Fix for texture upload logic.
Fix for texture upload logic.

sereepap2029/playcanvas,maxwellalive/engine,maxwellalive/engine,shinate/engine,sanyaade-teachings/engine,RainsSoft/engine,3DGEOM/engine,guycalledfrank/engine,horryq/engine-1,RainsSoft/engine,3DGEOM/engine,SuperStarPL/engine,playcanvas/engine,sereepap2029/playcanvas,aidinabedi/playcanvas-engine,H1Gdev/engine,sereepap2029/playcanvas,shinate/engine,nizihabi/engine,guycalledfrank/engine,shinate/engine,playcanvas/engine,sanyaade-teachings/engine,MicroWorldwide/PlayCanvas,MicroWorldwide/PlayCanvas,SuperStarPL/engine,H1Gdev/engine,sanyaade-teachings/engine,RainsSoft/engine,aidinabedi/playcanvas-engine,horryq/engine-1,horryq/engine-1,maxwellalive/engine,SuperStarPL/engine,3DGEOM/engine,nizihabi/engine,nizihabi/engine