bug fixed about not resizing