Skip to content

Commit

Permalink
update comments
Browse files Browse the repository at this point in the history
  • Loading branch information
themiswang committed Oct 19, 2023
1 parent a15117c commit 3ee007c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 2 additions & 0 deletions Crashlytics/Crashlytics/Components/FIRCLSApplication.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ NSString* FIRCLSApplicationGetSDKBundleID(void);
/**
* Returns the platform identifier, either: ios, mac, or tvos.
* Catalyst apps are treated as mac.
* This is a legacy function, for platform identificaiton please use
* FIRCLSApplicationGetFirebasePlatform.
*/
NSString* FIRCLSApplicationGetPlatform(void);

Expand Down
6 changes: 4 additions & 2 deletions Crashlytics/Crashlytics/Components/FIRCLSApplication.m
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@
[@"com.google.firebase.crashlytics." stringByAppendingString:FIRCLSApplicationGetPlatform()];
}

// Legacy function, we use FIRCLSApplicationGetFirebasePlatform now for platform specification.
// Can't clean the code since some endpoints setup depend on this function.
NSString* FIRCLSApplicationGetPlatform(void) {
#if defined(TARGET_OS_MACCATALYST) && TARGET_OS_MACCATALYST
return @"mac";
Expand All @@ -47,9 +49,9 @@
#elif TARGET_OS_TV
return @"tvos";
#elif TARGET_OS_WATCH
return @"ios"; // TODO: temporarily use iOS until Firebase can add watchos to the backend
return @"ios";
#elif defined(TARGET_OS_VISION) && TARGET_OS_VISION
return @"ios"; // TODO: temporarily use iOS until Firebase can add visionos to the backend
return @"ios";
#endif
}

Expand Down

0 comments on commit 3ee007c

Please sign in to comment.