From fa7bdea02950b2d3ded4d5d4d2264f9c21283c0e Mon Sep 17 00:00:00 2001 From: Ross Goldberg <484615+rgoldberg@users.noreply.github.com> Date: Sat, 5 Oct 2024 18:08:42 -0400 Subject: [PATCH] Fix breaking lint issue in MasStoreSearch.swift. Resolve #546 Signed-off-by: Ross Goldberg <484615+rgoldberg@users.noreply.github.com> --- Sources/MasKit/Controllers/MasStoreSearch.swift | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Sources/MasKit/Controllers/MasStoreSearch.swift b/Sources/MasKit/Controllers/MasStoreSearch.swift index f5a32e4..43b96c6 100644 --- a/Sources/MasKit/Controllers/MasStoreSearch.swift +++ b/Sources/MasKit/Controllers/MasStoreSearch.swift @@ -122,8 +122,8 @@ class MasStoreSearch: StoreSearch { firstly { networkManager.loadData(from: pageUrl) }.map { data in - let html = String(decoding: data, as: UTF8.self) - guard let capture = MasStoreSearch.appVersionExpression.firstMatch(in: html)?.captures[0], + guard let html = String(data: data, encoding: .utf8), + let capture = MasStoreSearch.appVersionExpression.firstMatch(in: html)?.captures[0], let version = Version(tolerant: capture) else { return nil