add debugging to resolve problem