Bug fix for body resizing