bug fix for debugging option