use logger instead of puts