fix bug about side expansion