Rename some uses of *Url as *URL.

Partial #585

Signed-off-by: Ross Goldberg <484615+rgoldberg@users.noreply.github.com>
This commit is contained in:
Ross Goldberg 2024-10-25 13:08:50 -04:00
parent 0b11f3737c
commit 59a642590a
No known key found for this signature in database

View file

@ -77,12 +77,12 @@ class MasStoreSearch: StoreSearch {
return .value(nil) return .value(nil)
} }
guard let pageUrl = URL(string: result.trackViewUrl) else { guard let pageURL = URL(string: result.trackViewUrl) else {
return .value(result) return .value(result)
} }
return firstly { return firstly {
self.scrapeAppStoreVersion(pageUrl) self.scrapeAppStoreVersion(pageURL)
} }
.map { pageVersion in .map { pageVersion in
guard let pageVersion, guard let pageVersion,
@ -120,9 +120,9 @@ class MasStoreSearch: StoreSearch {
/// Scrape the app version from the App Store webpage at the given URL. /// Scrape the app version from the App Store webpage at the given URL.
/// ///
/// App Store webpages frequently report a version that is newer than what is reported by the iTunes Search API. /// App Store webpages frequently report a version that is newer than what is reported by the iTunes Search API.
private func scrapeAppStoreVersion(_ pageUrl: URL) -> Promise<Version?> { private func scrapeAppStoreVersion(_ pageURL: URL) -> Promise<Version?> {
firstly { firstly {
networkManager.loadData(from: pageUrl) networkManager.loadData(from: pageURL)
} }
.map { data in .map { data in
guard let html = String(data: data, encoding: .utf8), guard let html = String(data: data, encoding: .utf8),