[issue #3] adding debug code