fixed bug where extra br elements were not being removed after taking