hopfully fixed logging