Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3370706
D8803.id29854.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D8803.id29854.diff
View Options
diff --git a/native/android/app/src/cpp/PlatformSpecificTools.cpp b/native/android/app/src/cpp/PlatformSpecificTools.cpp
--- a/native/android/app/src/cpp/PlatformSpecificTools.cpp
+++ b/native/android/app/src/cpp/PlatformSpecificTools.cpp
@@ -31,6 +31,12 @@
cls->getStaticMethod<JString()>("getNotificationsCryptoAccountPath");
return method(cls)->toStdString();
}
+
+ static bool isStaffRelease() {
+ static const auto cls = javaClassStatic();
+ static auto method = cls->getStaticMethod<jboolean()>("isStaffRelease");
+ return method(cls);
+ }
};
namespace comm {
@@ -55,4 +61,12 @@
return path;
}
+bool PlatformSpecificTools::isStaffRelease() {
+ bool staffRelease;
+ NativeAndroidAccessProvider::runTask([&staffRelease]() {
+ staffRelease = PlatformSpecificToolsJavaClass::isStaffRelease();
+ });
+ return staffRelease;
+}
+
} // namespace comm
diff --git a/native/android/app/src/main/java/app/comm/android/fbjni/PlatformSpecificTools.java b/native/android/app/src/main/java/app/comm/android/fbjni/PlatformSpecificTools.java
--- a/native/android/app/src/main/java/app/comm/android/fbjni/PlatformSpecificTools.java
+++ b/native/android/app/src/main/java/app/comm/android/fbjni/PlatformSpecificTools.java
@@ -26,4 +26,8 @@
.getFileStreamPath("comm_notifications_crypto_account")
.getPath();
}
+
+ public static boolean isStaffRelease() {
+ return false;
+ }
}
diff --git a/native/cpp/CommonCpp/Tools/PlatformSpecificTools.h b/native/cpp/CommonCpp/Tools/PlatformSpecificTools.h
--- a/native/cpp/CommonCpp/Tools/PlatformSpecificTools.h
+++ b/native/cpp/CommonCpp/Tools/PlatformSpecificTools.h
@@ -9,6 +9,7 @@
static void generateSecureRandomBytes(crypto::OlmBuffer &buffer, size_t size);
static std::string getDeviceOS();
static std::string getNotificationsCryptoAccountPath();
+ static bool isStaffRelease();
};
} // namespace comm
diff --git a/native/ios/Comm/PlatformSpecificTools.mm b/native/ios/Comm/PlatformSpecificTools.mm
--- a/native/ios/Comm/PlatformSpecificTools.mm
+++ b/native/ios/Comm/PlatformSpecificTools.mm
@@ -37,4 +37,8 @@
.path UTF8String]);
}
+bool PlatformSpecificTools::isStaffRelease() {
+ return false;
+}
+
}; // namespace comm
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Nov 27, 3:50 AM (15 h, 29 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2587613
Default Alt Text
D8803.id29854.diff (2 KB)
Attached To
Mode
D8803: Implement isStaffRelease method in PlatformSpecificTools
Attached
Detach File
Event Timeline
Log In to Comment