customize log fn