From 770776d19f3270ba708081f6bd607136e2dbd132 Mon Sep 17 00:00:00 2001 From: themiswang Date: Thu, 19 Oct 2023 14:56:23 -0400 Subject: [PATCH] update comments (#11968) --- Crashlytics/Crashlytics/Components/FIRCLSApplication.h | 2 ++ Crashlytics/Crashlytics/Components/FIRCLSApplication.m | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Crashlytics/Crashlytics/Components/FIRCLSApplication.h b/Crashlytics/Crashlytics/Components/FIRCLSApplication.h index 13934d0b313..d388f012764 100644 --- a/Crashlytics/Crashlytics/Components/FIRCLSApplication.h +++ b/Crashlytics/Crashlytics/Components/FIRCLSApplication.h @@ -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); diff --git a/Crashlytics/Crashlytics/Components/FIRCLSApplication.m b/Crashlytics/Crashlytics/Components/FIRCLSApplication.m index cf6a1f388c3..e1a0db632ec 100644 --- a/Crashlytics/Crashlytics/Components/FIRCLSApplication.m +++ b/Crashlytics/Crashlytics/Components/FIRCLSApplication.m @@ -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"; @@ -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 }