add debug log for mimetype