Skip to content

Commit

Permalink
UpdateCheckService: Move unofficial build check inside update JSON re…
Browse files Browse the repository at this point in the history
…sponse handling
  • Loading branch information
OatmealDome committed Jan 24, 2023
1 parent 0d80799 commit 65f88bb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Source/iOS/App/Common/Services/UpdateCheckService.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@ class UpdateCheckService : UIResponder, UIApplicationDelegate {
return true
}

if (versionManager.buildSource != .official) {
return true
}

let session = URLSession(configuration: URLSessionConfiguration.ephemeral)
let updateUrl = URL(string: "https://dolphinios.oatmealdome.me/api/v2/update.json")!

session.dataTask(with: updateUrl) { (data, response, error) in
if (versionManager.buildSource != .official) {
return
}

guard let unwrappedData = data else {
return
}
Expand Down

0 comments on commit 65f88bb

Please sign in to comment.