added loggong option