added custom logging function