Skip to content

Commit

Permalink
Merge pull request #702 from planetary-social/fix-unlimited-event-dow…
Browse files Browse the repository at this point in the history
…nload

Fix bug where we could accidentally subscribe to the relay firehose
  • Loading branch information
mplorentz authored Dec 6, 2023
2 parents a3acaf0 + 3dd9f7f commit 58b8714
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 14 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

- Fixed a bug where the app could become unresponsive.
- Added the option to copy the NIP-05 identifier when browsing a profile.
- Tapping on a tab bar icon can let you scroll to top.
- Fixed a bug where a root note could be rendered as a reply
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,17 +86,17 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/SDWebImage/SDWebImage.git",
"state" : {
"revision" : "36e484b317522667a4b2de9b50daaa01dfa30809",
"version" : "5.18.0"
"revision" : "1b9a2e902cbde5fdf362faa0f4fd76ea74d74305",
"version" : "5.18.5"
}
},
{
"identity" : "sdwebimageswiftui",
"kind" : "remoteSourceControl",
"location" : "https://github.com/SDWebImage/SDWebImageSwiftUI",
"state" : {
"revision" : "e837c37d45449fbd3b4745c10c5b5274e73edead",
"version" : "2.2.3"
"revision" : "aee64ef39b570c44ccf0f884c440fc6494a23c76",
"version" : "2.2.5"
}
},
{
Expand All @@ -113,8 +113,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/getsentry/sentry-cocoa.git",
"state" : {
"revision" : "d062d9b31ccabdec706134f2216476d1996caf11",
"version" : "8.10.0"
"revision" : "a3e15ba9fd6c8efc6515ad9d6f3337bb2dc2e1e3",
"version" : "8.17.0"
}
},
{
Expand Down Expand Up @@ -158,8 +158,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-collections.git",
"state" : {
"revision" : "937e904258d22af6e447a0b72c0bc67583ef64a2",
"version" : "1.0.4"
"revision" : "a902f1823a7ff3c9ab2fba0f992396b948eda307",
"version" : "1.0.5"
}
},
{
Expand All @@ -180,6 +180,15 @@
"version" : "0.1.4"
}
},
{
"identity" : "swift-http-types",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-http-types",
"state" : {
"revision" : "99d066e29effa8845e4761dd3f2f831edfdf8925",
"version" : "1.0.0"
}
},
{
"identity" : "swift-log",
"kind" : "remoteSourceControl",
Expand All @@ -194,17 +203,26 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio.git",
"state" : {
"revision" : "3db5c4aeee8100d2db6f1eaf3864afdad5dc68fd",
"version" : "2.59.0"
"revision" : "702cd7c56d5d44eeba73fdf83918339b26dc855c",
"version" : "2.62.0"
}
},
{
"identity" : "swift-nio-extras",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-extras.git",
"state" : {
"revision" : "fb70a0f5e984f23be48b11b4f1909f3bee016178",
"version" : "1.19.1"
"revision" : "798c962495593a23fdea0c0c63fd55571d8dff51",
"version" : "1.20.0"
}
},
{
"identity" : "swift-nio-http2",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-http2.git",
"state" : {
"revision" : "3bd9004b9d685ed6b629760fc84903e48efec806",
"version" : "1.29.0"
}
},
{
Expand All @@ -221,8 +239,8 @@
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-nio-transport-services.git",
"state" : {
"revision" : "e7403c35ca6bb539a7ca353b91cc2d8ec0362d58",
"version" : "1.19.0"
"revision" : "ebf8b9c365a6ce043bf6e6326a04b15589bd285e",
"version" : "1.20.0"
}
},
{
Expand Down
4 changes: 4 additions & 0 deletions Nos/Views/AuthorStoryView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,10 @@ struct AuthorStoryView: View {
subscriptionIDs.removeAll()
}
let eTags = notes.compactMap { $0.identifier }
guard !eTags.isEmpty else {
return
}

let filter = Filter(kinds: [.text, .like, .delete, .repost], eTags: eTags)
let subID = await relayService.openSubscription(with: filter)
subscriptionIDs.append(subID)
Expand Down

0 comments on commit 58b8714

Please sign in to comment.