 Chromium Code Reviews
 Chromium Code Reviews Issue 1701313002:
  Partial implementation of subscription restrictions.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/src.git@master
    
  
    Issue 1701313002:
  Partial implementation of subscription restrictions.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/src.git@master| Index: content/child/push_messaging/push_provider.cc | 
| diff --git a/content/child/push_messaging/push_provider.cc b/content/child/push_messaging/push_provider.cc | 
| index f8e807def7b5d4bd2efdb117b54083bacd006298..9c3de1eb56b7d52e69b8b6967a613f3130b4abbc 100644 | 
| --- a/content/child/push_messaging/push_provider.cc | 
| +++ b/content/child/push_messaging/push_provider.cc | 
| @@ -75,8 +75,13 @@ void PushProvider::subscribe( | 
| subscription_callbacks_.AddWithID(callbacks, request_id); | 
| int64_t service_worker_registration_id = | 
| GetServiceWorkerRegistrationId(service_worker_registration); | 
| + PushSubscriptionOptions content_options; | 
| + content_options.user_visible_only = options.userVisibleOnly; | 
| + // If subscription restrictions aren't enabled or a key isn't provided | 
| + // by the client, the sender id will be read from the database. | 
| + content_options.sender_info = options.applicationServerKey.utf8(); | 
| 
Peter Beverloo
2016/02/18 11:39:43
This would be a bug already: the |sender_info| is
 
harkness
2016/02/22 15:40:43
I've removed the flag on the SubscriptionOptions,
 | 
| thread_safe_sender_->Send(new PushMessagingHostMsg_SubscribeFromWorker( | 
| - request_id, service_worker_registration_id, options.userVisibleOnly)); | 
| + request_id, service_worker_registration_id, content_options)); | 
| } | 
| void PushProvider::unsubscribe( |