bug in logging