debug mode added
bug fixed