Imrpove logging