Fixed regression caused when changing logging.

The regression was cause in the branch of e473314.