refactor - log