From 2b68ab3f49f5888e3817ab2cfc0918b589019d80 Mon Sep 17 00:00:00 2001 From: Nathan Mattes Date: Fri, 3 Jan 2025 12:32:59 +0100 Subject: [PATCH] Fix more warnings (#2453) --- deltachat-ios/Chat/ChatViewController.swift | 2 +- deltachat-ios/Controller/WebViewViewController.swift | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/deltachat-ios/Chat/ChatViewController.swift b/deltachat-ios/Chat/ChatViewController.swift index 07ab6ce79..99ad34629 100644 --- a/deltachat-ios/Chat/ChatViewController.swift +++ b/deltachat-ios/Chat/ChatViewController.swift @@ -247,7 +247,7 @@ class ChatViewController: UITableViewController, UITableViewDropDelegate { tableView.contentInsetAdjustmentBehavior = .never tableView.automaticallyAdjustsScrollIndicatorInsets = false tableView.publisher(for: \.contentInset) - .assign(to: \.scrollIndicatorInsets, on: tableView) + .assign(to: \.verticalScrollIndicatorInsets, on: tableView) .store(in: &bag) navigationController?.setNavigationBarHidden(false, animated: false) diff --git a/deltachat-ios/Controller/WebViewViewController.swift b/deltachat-ios/Controller/WebViewViewController.swift index dd5c8e3e2..df005de56 100644 --- a/deltachat-ios/Controller/WebViewViewController.swift +++ b/deltachat-ios/Controller/WebViewViewController.swift @@ -1,5 +1,5 @@ import UIKit -import WebKit +@preconcurrency import WebKit import DcCore class WebViewViewController: UIViewController, WKNavigationDelegate { @@ -130,7 +130,7 @@ class WebViewViewController: UIViewController, WKNavigationDelegate { } do { let data: Data = try Data(contentsOf: path) - let jsCode: String = String(decoding: data, as: UTF8.self) + let jsCode = String(data: data, encoding: .utf8) // inject the search code webView.evaluateJavaScript(jsCode, completionHandler: { _, error in logger.error("\(String(describing: error))")