#38 added debug logs