changed logging implementation