Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(197)

Unified Diff: components/gcm_driver/instance_id/instance_id_android.cc

Issue 2697793004: Push API: Validate storage before returning cached subscriptions (Closed)
Patch Set: Fix include Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/gcm_driver/instance_id/instance_id_android.cc
diff --git a/components/gcm_driver/instance_id/instance_id_android.cc b/components/gcm_driver/instance_id/instance_id_android.cc
index 7300a8ceaaa5734f66a7942effc45800704c2e0f..e18835bf1ef88582a12b66825a62e10e3c973888 100644
--- a/components/gcm_driver/instance_id/instance_id_android.cc
+++ b/components/gcm_driver/instance_id/instance_id_android.cc
@@ -121,6 +121,15 @@ void InstanceIDAndroid::GetToken(
base::android::ToJavaArrayOfStrings(env, options_strings));
}
+void InstanceIDAndroid::ValidateToken(const std::string& authorized_entity,
+ const std::string& scope,
+ const std::string& token,
+ const ValidateTokenCallback& callback) {
+ // gcm_driver doesn't store tokens on Android, so assume it's valid.
+ base::ThreadTaskRunnerHandle::Get()->PostTask(
+ FROM_HERE, base::Bind(callback, true /* is_valid */));
+}
+
void InstanceIDAndroid::DeleteTokenImpl(const std::string& authorized_entity,
const std::string& scope,
const DeleteTokenCallback& callback) {
« no previous file with comments | « components/gcm_driver/instance_id/instance_id_android.h ('k') | components/gcm_driver/instance_id/instance_id_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698