Trim extra space