Skip to content

Commit

Permalink
Merge branch 'np/v3-performance' of https://github.com/xmtp/xmtp-reac…
Browse files Browse the repository at this point in the history
…t-native into np/performance-inbox-id
  • Loading branch information
nplasterer committed Nov 2, 2024
2 parents 5a145f6 + 9ebc0bd commit ad44835
Show file tree
Hide file tree
Showing 12 changed files with 359 additions and 379 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,6 @@ class DmWrapper {
put("version", "DM")
put("topic", dm.topic)
put("peerInboxId", dm.peerInboxId)
if (dmParams.members) {
put("members", dm.members().map { MemberWrapper.encode(it) })
}
if (dmParams.creatorInboxId) put("creatorInboxId", dm.creatorInboxId())
if (dmParams.consentState) {
put("consentState", consentStateToString(dm.consentState()))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,6 @@ class GroupWrapper {
put("createdAt", group.createdAt.time)
put("version", "GROUP")
put("topic", group.topic)
if (groupParams.members) {
put("members", group.members().map { MemberWrapper.encode(it) })
}
if (groupParams.creatorInboxId) put("creatorInboxId", group.creatorInboxId())
if (groupParams.isActive) put("isActive", group.isActive())
if (groupParams.addedByInboxId) put("addedByInboxId", group.addedByInboxId())
Expand Down Expand Up @@ -54,7 +51,6 @@ class GroupWrapper {
}

class ConversationParamsWrapper(
val members: Boolean = true,
val creatorInboxId: Boolean = true,
val isActive: Boolean = true,
val addedByInboxId: Boolean = true,
Expand All @@ -69,7 +65,6 @@ class ConversationParamsWrapper(
if (conversationParams.isEmpty()) return ConversationParamsWrapper()
val jsonOptions = JsonParser.parseString(conversationParams).asJsonObject
return ConversationParamsWrapper(
if (jsonOptions.has("members")) jsonOptions.get("members").asBoolean else true,
if (jsonOptions.has("creatorInboxId")) jsonOptions.get("creatorInboxId").asBoolean else true,
if (jsonOptions.has("isActive")) jsonOptions.get("isActive").asBoolean else true,
if (jsonOptions.has("addedByInboxId")) jsonOptions.get("addedByInboxId").asBoolean else true,
Expand Down
Loading

0 comments on commit ad44835

Please sign in to comment.