Skip to content

Commit 0b253d1

Browse files
authored
Handle missing limit and next parameters in the file listing method (#223)
fix: Handle missing `limit` and `next` parameters in the `listFiles(channel:limit:next:custom:completion:)` method test: Add more integration tests
1 parent 55ebe94 commit 0b253d1

14 files changed

+1369
-669
lines changed

.pubnub.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,14 @@
11
---
22
name: swift
33
scm: github.com/pubnub/swift
4-
version: "9.3.3"
4+
version: "9.3.4"
55
schema: 1
66
changelog:
7+
- date: 2025-09-15
8+
version: 9.3.4
9+
changes:
10+
- type: bug
11+
text: "Handle missing `limit` and `next` parameters in the `listFiles(channel:limit:next:custom:completion:)` method."
712
- date: 2025-08-07
813
version: 9.3.3
914
changes:
@@ -723,7 +728,7 @@ sdks:
723728
- distribution-type: source
724729
distribution-repository: GitHub release
725730
package-name: PubNub
726-
location: https://github.com/pubnub/swift/archive/refs/tags/9.3.3.zip
731+
location: https://github.com/pubnub/swift/archive/refs/tags/9.3.4.zip
727732
supported-platforms:
728733
supported-operating-systems:
729734
macOS:

PubNub.xcodeproj/project.pbxproj

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -422,6 +422,8 @@
422422
3D38A02E2B35B087006928E7 /* LegacySubscriptionSessionStrategy.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D38A02A2B35B087006928E7 /* LegacySubscriptionSessionStrategy.swift */; };
423423
3D38A0302B35B208006928E7 /* subscription_handshake_success.json in Resources */ = {isa = PBXBuildFile; fileRef = 3D38A02F2B35B208006928E7 /* subscription_handshake_success.json */; };
424424
3D3C38832C47D62700E782E7 /* KMPError.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D3C38822C47D62700E782E7 /* KMPError.swift */; };
425+
3D3E28B82E69C310009B55E0 /* MembershipsEndpointIntegrationTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D3E28B72E69C310009B55E0 /* MembershipsEndpointIntegrationTests.swift */; };
426+
3D3E28BA2E6ADF00009B55E0 /* MembersEndpointIntegrationTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D3E28B92E6ADF00009B55E0 /* MembersEndpointIntegrationTests.swift */; };
425427
3D452B252C05DF6D008987D4 /* KMPHereNowResult.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D452B242C05DF6D008987D4 /* KMPHereNowResult.swift */; };
426428
3D4ED42F2B519FC500FE58C7 /* SubscriptionSessionTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 3D4ED42E2B519FC500FE58C7 /* SubscriptionSessionTests.swift */; };
427429
3D5BE9AE2BCEA5B50091ACA7 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = 3D34160A2BB5832E008558A0 /* PrivacyInfo.xcprivacy */; };
@@ -1050,6 +1052,8 @@
10501052
3D38A02A2B35B087006928E7 /* LegacySubscriptionSessionStrategy.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = LegacySubscriptionSessionStrategy.swift; sourceTree = "<group>"; };
10511053
3D38A02F2B35B208006928E7 /* subscription_handshake_success.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = subscription_handshake_success.json; sourceTree = "<group>"; };
10521054
3D3C38822C47D62700E782E7 /* KMPError.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KMPError.swift; sourceTree = "<group>"; };
1055+
3D3E28B72E69C310009B55E0 /* MembershipsEndpointIntegrationTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MembershipsEndpointIntegrationTests.swift; sourceTree = "<group>"; };
1056+
3D3E28B92E6ADF00009B55E0 /* MembersEndpointIntegrationTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MembersEndpointIntegrationTests.swift; sourceTree = "<group>"; };
10531057
3D452B242C05DF6D008987D4 /* KMPHereNowResult.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KMPHereNowResult.swift; sourceTree = "<group>"; };
10541058
3D4ED42E2B519FC500FE58C7 /* SubscriptionSessionTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SubscriptionSessionTests.swift; sourceTree = "<group>"; };
10551059
3D6265D62ABCA79100FDD5E6 /* CryptorUtils.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CryptorUtils.swift; sourceTree = "<group>"; };
@@ -1401,6 +1405,8 @@
14011405
3DADDF962DCB4E8E001564C3 /* ChannelGroupEndpointIntegrationTests.swift */,
14021406
3D0934352DD33A74007132B1 /* FilesEndpointIntegrationTests.swift */,
14031407
3D2AF8BC2DD72CEB009303B6 /* HistoryEndpointIntegrationTests.swift */,
1408+
3D3E28B72E69C310009B55E0 /* MembershipsEndpointIntegrationTests.swift */,
1409+
3D3E28B92E6ADF00009B55E0 /* MembersEndpointIntegrationTests.swift */,
14041410
3DADDF942DCB4776001564C3 /* Helpers */,
14051411
);
14061412
path = Integration;
@@ -3413,10 +3419,12 @@
34133419
35293AA2236B51A00049A71F /* PubNub+Integration.swift in Sources */,
34143420
3DADDF972DCB4E8E001564C3 /* ChannelGroupEndpointIntegrationTests.swift in Sources */,
34153421
3562DBBD23429798006DFFBC /* UserObjectsEndpointIntegrationTests.swift in Sources */,
3422+
3D3E28BA2E6ADF00009B55E0 /* MembersEndpointIntegrationTests.swift in Sources */,
34163423
35293A9A236A1DE70049A71F /* MessageActionsEndpointIntegrationTests.swift in Sources */,
34173424
3D2AF8BD2DD72CEB009303B6 /* HistoryEndpointIntegrationTests.swift in Sources */,
34183425
3562DBC1234408DC006DFFBC /* ChannelObjectsEndpointIntegrationTests.swift in Sources */,
34193426
3DAB7C512DD5047F0003D693 /* XCTestCase+Integration.swift in Sources */,
3427+
3D3E28B82E69C310009B55E0 /* MembershipsEndpointIntegrationTests.swift in Sources */,
34203428
3D0934362DD33A74007132B1 /* FilesEndpointIntegrationTests.swift in Sources */,
34213429
359287C7232712520046F7A2 /* PresenceEndpointIntegrationTests.swift in Sources */,
34223430
3520962F2358D64C00A641DF /* TestSetup.swift in Sources */,
@@ -4035,7 +4043,7 @@
40354043
"@loader_path/Frameworks",
40364044
);
40374045
MACOSX_DEPLOYMENT_TARGET = 10.15;
4038-
MARKETING_VERSION = 9.3.3;
4046+
MARKETING_VERSION = 9.3.4;
40394047
MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu11 gnu++17";
40404048
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
40414049
MTL_FAST_MATH = YES;
@@ -4086,7 +4094,7 @@
40864094
"@loader_path/Frameworks",
40874095
);
40884096
MACOSX_DEPLOYMENT_TARGET = 10.15;
4089-
MARKETING_VERSION = 9.3.3;
4097+
MARKETING_VERSION = 9.3.4;
40904098
MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu11 gnu++17";
40914099
MTL_ENABLE_DEBUG_INFO = NO;
40924100
MTL_FAST_MATH = YES;
@@ -4194,7 +4202,7 @@
41944202
"@loader_path/Frameworks",
41954203
);
41964204
MACOSX_DEPLOYMENT_TARGET = 10.15;
4197-
MARKETING_VERSION = 9.3.3;
4205+
MARKETING_VERSION = 9.3.4;
41984206
MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu11 gnu++17";
41994207
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
42004208
MTL_FAST_MATH = YES;
@@ -4247,7 +4255,7 @@
42474255
"@loader_path/Frameworks",
42484256
);
42494257
MACOSX_DEPLOYMENT_TARGET = 10.15;
4250-
MARKETING_VERSION = 9.3.3;
4258+
MARKETING_VERSION = 9.3.4;
42514259
MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu11 gnu++17";
42524260
MTL_ENABLE_DEBUG_INFO = NO;
42534261
MTL_FAST_MATH = YES;
@@ -4368,7 +4376,7 @@
43684376
"@loader_path/Frameworks",
43694377
);
43704378
MACOSX_DEPLOYMENT_TARGET = 10.15;
4371-
MARKETING_VERSION = 9.3.3;
4379+
MARKETING_VERSION = 9.3.4;
43724380
MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu11 gnu++17";
43734381
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
43744382
MTL_FAST_MATH = YES;
@@ -4420,7 +4428,7 @@
44204428
"@loader_path/Frameworks",
44214429
);
44224430
MACOSX_DEPLOYMENT_TARGET = 10.15;
4423-
MARKETING_VERSION = 9.3.3;
4431+
MARKETING_VERSION = 9.3.4;
44244432
MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu11 gnu++17";
44254433
MTL_ENABLE_DEBUG_INFO = NO;
44264434
MTL_FAST_MATH = YES;
@@ -4900,7 +4908,7 @@
49004908
"$(TOOLCHAIN_DIR)/usr/lib/swift/macosx",
49014909
);
49024910
MACOSX_DEPLOYMENT_TARGET = 10.15;
4903-
MARKETING_VERSION = 9.3.3;
4911+
MARKETING_VERSION = 9.3.4;
49044912
MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu17 gnu++14";
49054913
OTHER_CFLAGS = "$(inherited)";
49064914
OTHER_LDFLAGS = "$(inherited)";
@@ -4943,7 +4951,7 @@
49434951
"$(TOOLCHAIN_DIR)/usr/lib/swift/macosx",
49444952
);
49454953
MACOSX_DEPLOYMENT_TARGET = 10.15;
4946-
MARKETING_VERSION = 9.3.3;
4954+
MARKETING_VERSION = 9.3.4;
49474955
MODULE_VERIFIER_SUPPORTED_LANGUAGE_STANDARDS = "gnu17 gnu++14";
49484956
OTHER_CFLAGS = "$(inherited)";
49494957
OTHER_LDFLAGS = "$(inherited)";

PubNubSwift.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |s|
22
s.name = 'PubNubSwift'
3-
s.version = '9.3.3'
3+
s.version = '9.3.4'
44
s.homepage = 'https://github.com/pubnub/swift'
55
s.documentation_url = 'https://www.pubnub.com/docs/swift-native/pubnub-swift-sdk'
66
s.authors = { 'PubNub, Inc.' => '[email protected]' }

Sources/PubNub/Helpers/Constants.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public enum Constant {
5757

5858
static let pubnubSwiftSDKName: String = "PubNubSwift"
5959

60-
static let pubnubSwiftSDKVersion: String = "9.3.3"
60+
static let pubnubSwiftSDKVersion: String = "9.3.4"
6161

6262
static let appBundleId: String = {
6363
if let info = Bundle.main.infoDictionary,

Sources/PubNub/Networking/HTTPRouter.swift

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ enum QueryKey: String {
124124
case sort
125125
case descending = "desc"
126126
case eventEngine = "ee"
127+
case next = "next"
127128
}
128129

129130
/// The PubNub Key requirement for a given Endpoint

Sources/PubNub/Networking/Routers/FileManagementRouter.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,9 +96,12 @@ struct FileManagementRouter: HTTPRouter {
9696
}
9797

9898
var queryItems: Result<[URLQueryItem], Error> {
99-
let query = defaultQueryItems
99+
var query = defaultQueryItems
100100

101101
switch endpoint {
102+
case let .list(_, limit, next):
103+
query.appendIfPresent(key: .limit, value: limit.description)
104+
query.appendIfPresent(key: .next, value: next)
102105
default:
103106
break
104107
}

0 commit comments

Comments
 (0)