query: add longform kind, add to home filter
This commit is contained in:
@@ -106,6 +106,7 @@ class HomeModel {
|
||||
|
||||
switch kind {
|
||||
case .chat: fallthrough
|
||||
case .longform: fallthrough
|
||||
case .text:
|
||||
handle_text_event(sub_id: sub_id, ev)
|
||||
case .contacts:
|
||||
@@ -406,8 +407,7 @@ class HomeModel {
|
||||
|
||||
// TODO: separate likes?
|
||||
var home_filter_kinds: [NostrKind] = [
|
||||
.text,
|
||||
.boost
|
||||
.text, .longform, .boost
|
||||
]
|
||||
if !damus_state.settings.onlyzaps_mode {
|
||||
home_filter_kinds.append(.like)
|
||||
|
||||
@@ -69,8 +69,7 @@ class ProfileModel: ObservableObject, Equatable {
|
||||
}
|
||||
|
||||
func subscribe() {
|
||||
var text_filter = NostrFilter(kinds: [.text, .chat])
|
||||
|
||||
var text_filter = NostrFilter(kinds: [.text, .longform])
|
||||
var profile_filter = NostrFilter(kinds: [.contacts, .metadata, .boost])
|
||||
|
||||
profile_filter.authors = [pubkey]
|
||||
|
||||
@@ -68,7 +68,7 @@ class NostrEvent: Codable, Identifiable, CustomStringConvertible, Equatable, Has
|
||||
let content: String
|
||||
|
||||
var is_textlike: Bool {
|
||||
return kind == 1 || kind == 42
|
||||
return kind == 1 || kind == 42 || kind == 30023
|
||||
}
|
||||
|
||||
var too_big: Bool {
|
||||
|
||||
@@ -20,6 +20,7 @@ enum NostrKind: Int, Codable {
|
||||
case channel_meta = 41
|
||||
case chat = 42
|
||||
case list = 30000
|
||||
case longform = 30023
|
||||
case zap = 9735
|
||||
case zap_request = 9734
|
||||
case nwc_request = 23194
|
||||
|
||||
Reference in New Issue
Block a user