Fixing resizing issues