added loging