Skip to content

Commit 3a79298

Browse files
committed
Merge pull request #731 from ParsePlatform/nlutsenko.devicetype
Add proper device type constant for tvOS/watchOS SDKs.
2 parents f12976f + 80bed35 commit 3a79298

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

Parse/PFConstants.m

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,14 @@
1111

1212
NSInteger const PARSE_API_VERSION = 2;
1313

14-
#if PARSE_IOS_ONLY
15-
NSString *const kPFDeviceType = @"ios";
16-
#else
17-
NSString *const kPFDeviceType = @"osx";
14+
#if TARGET_OS_IOS
15+
NSString *const kPFDeviceType = @"ios";
16+
#elif PF_TARGET_OS_OSX
17+
NSString *const kPFDeviceType = @"osx";
18+
#elif TARGET_OS_TV
19+
NSString *const kPFDeviceType = @"appletv";
20+
#elif TARGET_OS_WATCH
21+
NSString *const kPFDeviceType = @"applewatch";
1822
#endif
1923

2024
NSString *const PFParseErrorDomain = @"Parse";

0 commit comments

Comments
 (0)