finishes the handler.