proper logging added