Fixed wrong logging