delete nullptr is well-defined, does not need check. Manually fixed indentation after automatic changes.