move debug print statement