allow null when setting a logging closure