resize bugs fixed