updated logging
refactor more logging