Fix page encoding in IV on macOS.

This commit is contained in:
John Preston 2024-03-14 10:56:24 +04:00
parent 5133f74f67
commit 5c8e6c3012
2 changed files with 2 additions and 2 deletions

View file

@ -494,7 +494,7 @@ void Controller::createWebview(const QString &dataPath) {
|| index >= _pages.size()) {
return Webview::DataResult::Failed;
}
return finishWith(WrapPage(_pages[index]), "text/html");
return finishWith(WrapPage(_pages[index]), "text/html; charset=utf-8");
} else if (id.starts_with("page") && id.ends_with(".json")) {
auto index = 0;
const auto result = std::from_chars(

View file

@ -708,7 +708,7 @@ void Shown::streamMap(QString params, Webview::DataRequest request) {
void Shown::sendEmbed(QByteArray hash, Webview::DataRequest request) {
const auto i = _embeds.find(hash);
if (i != end(_embeds)) {
requestDone(std::move(request), i->second, "text/html");
requestDone(std::move(request), i->second, "text/html; charset=utf-8");
} else {
requestFail(std::move(request));
}