fix one time only creation bug for logger