updated compressStr and isRotation