Merge pull request #548 from rgoldberg/546-lint

Fix breaking lint issue in MasStoreSearch.swift.
This commit is contained in:
Ross Goldberg 2024-10-05 19:08:44 -04:00 committed by GitHub
commit 622a154fb9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -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