Simplify the polite-end script