fixing loging issue