from the beginning of this method here are the new code for logging. tested in my bf instance