Skip to content

Commit

Permalink
Fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
mplorentz committed Jul 17, 2024
1 parent cc24efd commit 1e1244c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions Nos/Service/Relay/RelayService.swift
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,6 @@ extension RelayService {
if let subID = responseArray[1] as? String,
let subscription = await subscriptionManager.subscription(from: subID),
subscription.closesAfterResponse {
Log.debug("\(socket.host) has finished responding on \(subID). Closing subscription.")
// This is a one-off request. Close it.
await sendClose(from: socket, subscriptionID: subID)
}
Expand All @@ -344,7 +343,7 @@ extension RelayService {
let jsonEvent = try JSONDecoder().decode(JSONEvent.self, from: jsonData)
await self.parseQueue.push(jsonEvent, from: socket)

if let subscription = await subscriptionManager.subscription(from: subscriptionID) {
if var subscription = await subscriptionManager.subscription(from: subscriptionID) {
if let oldestSeen = subscription.oldestEventCreationDate,
jsonEvent.createdDate < oldestSeen {
subscription.oldestEventCreationDate = jsonEvent.createdDate
Expand Down

0 comments on commit 1e1244c

Please sign in to comment.