Ignore case for type of savePage
This commit is contained in:
parent
4804d6b79b
commit
f7c0418bd8
1 changed files with 4 additions and 3 deletions
|
@ -169,11 +169,12 @@ struct Converter<content::SavePageType> {
|
||||||
std::string save_type;
|
std::string save_type;
|
||||||
if (!ConvertFromV8(isolate, val, &save_type))
|
if (!ConvertFromV8(isolate, val, &save_type))
|
||||||
return false;
|
return false;
|
||||||
if (save_type == "HTMLOnly") {
|
save_type = base::StringToLowerASCII(save_type);
|
||||||
|
if (save_type == "htmlonly") {
|
||||||
*out = content::SAVE_PAGE_TYPE_AS_ONLY_HTML;
|
*out = content::SAVE_PAGE_TYPE_AS_ONLY_HTML;
|
||||||
} else if (save_type == "HTMLComplete") {
|
} else if (save_type == "htmlcomplete") {
|
||||||
*out = content::SAVE_PAGE_TYPE_AS_COMPLETE_HTML;
|
*out = content::SAVE_PAGE_TYPE_AS_COMPLETE_HTML;
|
||||||
} else if (save_type == "MHTML") {
|
} else if (save_type == "mhtml") {
|
||||||
*out = content::SAVE_PAGE_TYPE_AS_MHTML;
|
*out = content::SAVE_PAGE_TYPE_AS_MHTML;
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
|
Loading…
Reference in a new issue