added content-type setting in debug mode in case it had been changed