Skip to content

Commit 33906aa

Browse files
committed
Remove filterTags from update and partial update since it is not supported by backend
1 parent 02909d1 commit 33906aa

File tree

4 files changed

+4
-22
lines changed

4 files changed

+4
-22
lines changed

CHANGELOG.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
1313
- Add `ChatChannel.filterTags`
1414
- Add `filterTags` channel list filtering key
1515
- Add `filterTags` argument to `ChatChannelController` and `Chat` factory methods in `ChatClient`
16-
- Add `filterTags` argument to `ChatChannelController.updateChannel` and `ChatChannelController.partialUpdateChannel`
17-
- Add `filterTags` argument to `Chat.update` and `Chat.updatePartial`
1816
### 🐞 Fixed
1917
- Fix rare crash in `WebSocketClient.connectEndpoint` [#3882](https://github.com/GetStream/stream-chat-swift/pull/3882)
2018
- Fix audio recordings not playing from AirPods automatically [#3884](https://github.com/GetStream/stream-chat-swift/pull/3884)

Sources/StreamChat/Controllers/ChannelController/ChannelController.swift

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,6 @@ public class ChatChannelController: DataController, DelegateCallable, DataStoreP
253253
/// - team: New team.
254254
/// - members: New members.
255255
/// - invites: New invites.
256-
/// - filterTags: A list of tags to add to the channel.
257256
/// - extraData: New `ExtraData`.
258257
/// - completion: The completion. Will be called on a **callbackQueue** when the network request is finished.
259258
/// If request fails, the completion will be called with an error.
@@ -264,7 +263,6 @@ public class ChatChannelController: DataController, DelegateCallable, DataStoreP
264263
team: String?,
265264
members: Set<UserId> = [],
266265
invites: Set<UserId> = [],
267-
filterTags: Set<String> = [],
268266
extraData: [String: RawJSON] = [:],
269267
completion: ((Error?) -> Void)? = nil
270268
) {
@@ -281,7 +279,7 @@ public class ChatChannelController: DataController, DelegateCallable, DataStoreP
281279
team: team,
282280
members: members,
283281
invites: invites,
284-
filterTags: filterTags,
282+
filterTags: [],
285283
extraData: extraData
286284
)
287285

@@ -298,7 +296,6 @@ public class ChatChannelController: DataController, DelegateCallable, DataStoreP
298296
/// - team: New team.
299297
/// - members: New members.
300298
/// - invites: New invites.
301-
/// - filterTags: A list of tags to add to the channel.
302299
/// - extraData: New `ExtraData`.
303300
/// - unsetProperties: Properties from the channel that are going to be cleared/unset.
304301
/// - completion: The completion. Will be called on a **callbackQueue** when the network request is finished.
@@ -310,7 +307,6 @@ public class ChatChannelController: DataController, DelegateCallable, DataStoreP
310307
team: String? = nil,
311308
members: Set<UserId> = [],
312309
invites: Set<UserId> = [],
313-
filterTags: Set<String> = [],
314310
extraData: [String: RawJSON] = [:],
315311
unsetProperties: [String] = [],
316312
completion: ((Error?) -> Void)? = nil
@@ -328,7 +324,7 @@ public class ChatChannelController: DataController, DelegateCallable, DataStoreP
328324
team: team,
329325
members: members,
330326
invites: invites,
331-
filterTags: filterTags,
327+
filterTags: [],
332328
extraData: extraData
333329
)
334330

Sources/StreamChat/StateLayer/Chat.swift

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1356,7 +1356,6 @@ public class Chat {
13561356
/// - team: The team for the channel.
13571357
/// - members: A list of members for the channel.
13581358
/// - invites: A list of users who will get invites.
1359-
/// - filterTags: A list of tags to add to the channel.
13601359
/// - extraData: Extra data for the new channel.
13611360
///
13621361
/// - Throws: An error while communicating with the Stream API.
@@ -1366,7 +1365,6 @@ public class Chat {
13661365
team: String?,
13671366
members: Set<UserId> = [],
13681367
invites: Set<UserId> = [],
1369-
filterTags: Set<String> = [],
13701368
extraData: [String: RawJSON] = [:]
13711369
) async throws {
13721370
try await channelUpdater.update(
@@ -1377,7 +1375,7 @@ public class Chat {
13771375
team: team,
13781376
members: members,
13791377
invites: invites,
1380-
filterTags: filterTags,
1378+
filterTags: [],
13811379
extraData: extraData
13821380
)
13831381
)
@@ -1394,7 +1392,6 @@ public class Chat {
13941392
/// - team: The team for the channel.
13951393
/// - members: A list of members for the channel.
13961394
/// - invites: A list of users who will get invites.
1397-
/// - filterTags: A list of tags to add to the channel.
13981395
/// - extraData: Extra data for the channel.
13991396
/// - unsetProperties: A list of properties to reset.
14001397
///
@@ -1405,7 +1402,6 @@ public class Chat {
14051402
team: String? = nil,
14061403
members: [UserId] = [],
14071404
invites: [UserId] = [],
1408-
filterTags: Set<String> = [],
14091405
extraData: [String: RawJSON] = [:],
14101406
unsetProperties: [String] = []
14111407
) async throws {
@@ -1417,7 +1413,7 @@ public class Chat {
14171413
team: team,
14181414
members: Set(members),
14191415
invites: Set(invites),
1420-
filterTags: filterTags,
1416+
filterTags: [],
14211417
extraData: extraData
14221418
),
14231419
unsetProperties: unsetProperties

Tests/StreamChatTests/StateLayer/Chat_Tests.swift

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1317,7 +1317,6 @@ final class Chat_Tests: XCTestCase {
13171317
let team = "team123"
13181318
let members: Set<UserId> = [.unique, .unique]
13191319
let invites: Set<UserId> = [.unique]
1320-
let filterTags: Set<String> = ["tag1", "tag2"]
13211320
let extraData: [String: RawJSON] = ["custom": .string("value")]
13221321

13231322
try await chat.update(
@@ -1326,7 +1325,6 @@ final class Chat_Tests: XCTestCase {
13261325
team: team,
13271326
members: members,
13281327
invites: invites,
1329-
filterTags: filterTags,
13301328
extraData: extraData
13311329
)
13321330

@@ -1336,7 +1334,6 @@ final class Chat_Tests: XCTestCase {
13361334
XCTAssertEqual(payload.team, team)
13371335
XCTAssertEqual(payload.members, members)
13381336
XCTAssertEqual(payload.invites, invites)
1339-
XCTAssertEqual(payload.filterTags, filterTags)
13401337
XCTAssertEqual(payload.extraData, extraData)
13411338
}
13421339

@@ -1350,7 +1347,6 @@ final class Chat_Tests: XCTestCase {
13501347
team: nil,
13511348
members: [],
13521349
invites: [],
1353-
filterTags: [],
13541350
extraData: [:]
13551351
),
13561352
expectedTestError
@@ -1364,7 +1360,6 @@ final class Chat_Tests: XCTestCase {
13641360
let team = "team123"
13651361
let members: [UserId] = [.unique, .unique]
13661362
let invites: [UserId] = [.unique]
1367-
let filterTags: Set<String> = ["tag1", "tag2"]
13681363
let extraData: [String: RawJSON] = ["custom": .string("value")]
13691364
let unsetProperties = ["property1", "property2"]
13701365

@@ -1374,7 +1369,6 @@ final class Chat_Tests: XCTestCase {
13741369
team: team,
13751370
members: members,
13761371
invites: invites,
1377-
filterTags: filterTags,
13781372
extraData: extraData,
13791373
unsetProperties: unsetProperties
13801374
)
@@ -1385,7 +1379,6 @@ final class Chat_Tests: XCTestCase {
13851379
XCTAssertEqual(payload.team, team)
13861380
XCTAssertEqual(payload.members, Set(members))
13871381
XCTAssertEqual(payload.invites, Set(invites))
1388-
XCTAssertEqual(payload.filterTags, filterTags)
13891382
XCTAssertEqual(payload.extraData, extraData)
13901383
XCTAssertEqual(env.channelUpdaterMock.partialChannelUpdate_unsetProperties, unsetProperties)
13911384
}
@@ -1400,7 +1393,6 @@ final class Chat_Tests: XCTestCase {
14001393
team: nil,
14011394
members: [],
14021395
invites: [],
1403-
filterTags: [],
14041396
extraData: [:],
14051397
unsetProperties: []
14061398
),

0 commit comments

Comments
 (0)