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

Unified Diff: third_party/WebKit/Source/modules/push_messaging/PushManager.cpp

Issue 1701313002: Partial implementation of subscription restrictions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed broken file Created 4 years, 10 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: third_party/WebKit/Source/modules/push_messaging/PushManager.cpp
diff --git a/third_party/WebKit/Source/modules/push_messaging/PushManager.cpp b/third_party/WebKit/Source/modules/push_messaging/PushManager.cpp
index 0f5a2ffd66ddd641444c5580ef3b4c3273ccc98d..9b9053e207071759f8b114655dd92249b0650433 100644
--- a/third_party/WebKit/Source/modules/push_messaging/PushManager.cpp
+++ b/third_party/WebKit/Source/modules/push_messaging/PushManager.cpp
@@ -38,6 +38,11 @@ WebPushSubscriptionOptions toWebPushSubscriptionOptions(const PushSubscriptionOp
{
WebPushSubscriptionOptions webOptions;
webOptions.userVisibleOnly = options.userVisibleOnly();
+ if (options.hasApplicationServerKey() && options.applicationServerKey()) {
+ webOptions.applicationServerKey = WebString::fromUTF8(
+ static_cast<const char*>(options.applicationServerKey()->data()),
+ options.applicationServerKey()->byteLength());
+ }
return webOptions;
}

Powered by Google App Engine
This is Rietveld 408576698