fix for initial resizing