remove end bracket