add closing brackets