Don't call end functions twice.

No need to call these here, they are called
after the function returns.