Skip to content
This repository was archived by the owner on Jul 22, 2020. It is now read-only.

Commit 74ba2d2

Browse files
committed
Make IterableConstants.h public and update it, fix one lint warning
1 parent 436dc03 commit 74ba2d2

File tree

3 files changed

+20
-3
lines changed

3 files changed

+20
-3
lines changed

Artifacts/include/Iterable-iOS-SDK/IterableConstants.h

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,21 @@ extern NSString *const ITBL_KEY_CURRENT_EMAIL;
1717
extern NSString *const ITBL_KEY_DATA_FIELDS;
1818
extern NSString *const ITBL_KEY_DEVICE;
1919
extern NSString *const ITBL_KEY_EMAIL;
20+
extern NSString *const ITBL_KEY_EMAIL_LIST_IDS;
2021
extern NSString *const ITBL_KEY_EVENT_NAME;
2122
extern NSString *const ITBL_KEY_ITEMS;
2223
extern NSString *const ITBL_KEY_MERGE_NESTED;
2324
extern NSString *const ITBL_KEY_MESSAGE_ID;
2425
extern NSString *const ITBL_KEY_NEW_EMAIL;
2526
extern NSString *const ITBL_KEY_PLATFORM;
2627
extern NSString *const ITBL_KEY_RECIPIENT_EMAIL;
28+
extern NSString *const ITBL_KEY_SDK_VERSION;
2729
extern NSString *const ITBL_KEY_SEND_AT;
2830
extern NSString *const ITBL_KEY_TOKEN;
2931
extern NSString *const ITBL_KEY_TEMPLATE_ID;
3032
extern NSString *const ITBL_KEY_TOTAL;
33+
extern NSString *const ITBL_KEY_UNSUB_CHANNEL;
34+
extern NSString *const ITBL_KEY_UNSUB_MESSAGE;
3135
extern NSString *const ITBL_KEY_USER;
3236
extern NSString *const ITBL_KEY_USER_ID;
3337

@@ -52,8 +56,9 @@ extern NSString *const ITBL_DEVICE_USER_INTERFACE;
5256
#define ENDPOINT_TRACK_INAPP_CLICK @"events/trackInAppClick"
5357
#define ENDPOINT_TRACK_INAPP_OPEN @"events/trackInAppOpen"
5458
#define ENDPOINT_TRACK_PUSH_OPEN @"events/trackPushOpen"
55-
#define ENDPOINT_UPDATE_EMAIL @"users/updateEmail"
5659
#define ENDPOINT_UPDATE_USER @"users/update"
60+
#define ENDPOINT_UPDATE_EMAIL @"users/updateEmail"
61+
#define ENDPOINT_UPDATE_SUBSCRIPTIONS @"users/updateSubscriptions"
5762

5863
//MISC
5964
#define ITBL_KEY_GET @"GET"
@@ -65,11 +70,15 @@ extern NSString *const ITBL_DEVICE_USER_INTERFACE;
6570
#define ITBL_KEY_PHONE @"Phone"
6671
#define ITBL_KEY_UNSPECIFIED @"Unspecified"
6772

73+
#define ITBL_PLATFORM_IOS @"iOS"
74+
6875

6976
#define ITBL_DEEPLINK_IDENTIFIER @"/a/[a-zA-Z0-9]+"
7077

7178

7279
//In-App Constants
80+
#define ITERABLE_IN_APP_CLICK_URL @"urlClick"
81+
7382
#define ITERABLE_IN_APP_TITLE @"title"
7483
#define ITERABLE_IN_APP_BODY @"body"
7584
#define ITERABLE_IN_APP_IMAGE @"mainImage"
@@ -90,5 +99,11 @@ extern NSString *const ITBL_DEVICE_USER_INTERFACE;
9099
#define ITERABLE_IN_APP_BUTTON_ACTION @"action"
91100
#define ITERABLE_IN_APP_CONTENT @"content"
92101

102+
//In-App HTML Constants
103+
#define ITERABLE_IN_APP_BACKGROUND_ALPHA @"backgroundAlpha"
104+
#define ITERABLE_IN_APP_HTML @"html"
105+
#define ITERABLE_IN_APP_HREF @"href"
106+
#define ITERABLE_IN_APP_DISPLAY_SETTINGS @"inAppDisplaySettings"
107+
93108

94109
typedef void (^ITEActionBlock)(NSString *);

Iterable-iOS-SDK.xcodeproj/project.pbxproj

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
161D98BD20236BC700E91846 /* IterableDeeplinkManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 161D98BB20236BC700E91846 /* IterableDeeplinkManager.m */; };
4141
16513DDE1D89EECC00C205B3 /* IterableInAppManager.h in Headers */ = {isa = PBXBuildFile; fileRef = 16513DD81D89EECC00C205B3 /* IterableInAppManager.h */; };
4242
16513DDF1D89EECC00C205B3 /* IterableInAppManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 16513DD91D89EECC00C205B3 /* IterableInAppManager.m */; };
43-
1653A80E1D88B25200690298 /* IterableConstants.h in Headers */ = {isa = PBXBuildFile; fileRef = 1653A80B1D88B25200690298 /* IterableConstants.h */; };
43+
1653A80E1D88B25200690298 /* IterableConstants.h in Headers */ = {isa = PBXBuildFile; fileRef = 1653A80B1D88B25200690298 /* IterableConstants.h */; settings = {ATTRIBUTES = (Public, ); }; };
4444
16E02BAD1E035EA400644C15 /* IterableConstants.m in Sources */ = {isa = PBXBuildFile; fileRef = 16E02BAC1E035EA400644C15 /* IterableConstants.m */; };
4545
6804B8601AC0F363000A126B /* CommerceItem.m in Sources */ = {isa = PBXBuildFile; fileRef = 6804B85F1AC0F363000A126B /* CommerceItem.m */; };
4646
6845F7331AC3831B0043629D /* SystemConfiguration.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6845F7321AC3831B0043629D /* SystemConfiguration.framework */; };
@@ -106,6 +106,7 @@
106106
9284CA73206DCA6C00404B74 /* IterableAPIResponseTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = IterableAPIResponseTests.m; sourceTree = "<group>"; };
107107
C67AA6DFEC454FF39AD12F3F /* Pods-Iterable-iOS-SDK.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Iterable-iOS-SDK.release.xcconfig"; path = "Pods/Target Support Files/Pods-Iterable-iOS-SDK/Pods-Iterable-iOS-SDK.release.xcconfig"; sourceTree = "<group>"; };
108108
DA3D876BD230574973D99AD7 /* Pods-Iterable-iOS-SDK.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Iterable-iOS-SDK.debug.xcconfig"; path = "Pods/Target Support Files/Pods-Iterable-iOS-SDK/Pods-Iterable-iOS-SDK.debug.xcconfig"; sourceTree = "<group>"; };
109+
E95162E4972E90805BB61534 /* .travis.yml */ = {isa = PBXFileReference; lastKnownFileType = file.yml; path = .travis.yml; sourceTree = "<group>"; };
109110
/* End PBXFileReference section */
110111

111112
/* Begin PBXFrameworksBuildPhase section */
@@ -138,6 +139,7 @@
138139
09C0FC0A1A1D6D4700D5A86B /* Iterable-iOS-SDKTests */,
139140
09C0FBFC1A1D6D4700D5A86B /* Products */,
140141
6E5391F86A2C1A9760767AA2 /* Pods */,
142+
E95162E4972E90805BB61534 /* .travis.yml */,
141143
);
142144
sourceTree = "<group>";
143145
};

Iterable-iOS-SDK/IterableAPI.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,7 @@ - (void)sendRequest:(NSURLRequest *)request onSuccess:(void (^)(NSDictionary *))
267267
if (onFailure != nil) onFailure(reason, nil);
268268
}
269269
} else {
270-
if (onFailure != nil) onFailure([NSString stringWithFormat:@"Received non-200 response: %d", responseCode], data);
270+
if (onFailure != nil) onFailure([NSString stringWithFormat:@"Received non-200 response: %ld", (long) responseCode], data);
271271
}
272272
}];
273273
[task resume];

0 commit comments

Comments
 (0)