Chromium Code Reviews| Index: content/test/mock_platform_notification_service.cc |
| diff --git a/content/test/mock_platform_notification_service.cc b/content/test/mock_platform_notification_service.cc |
| index 58db6968fe6370e92f3b5b40d25727755656d135..df3a32e783b7feebd3ebc6715d06b4850c7010da 100644 |
| --- a/content/test/mock_platform_notification_service.cc |
| +++ b/content/test/mock_platform_notification_service.cc |
| @@ -166,11 +166,9 @@ void MockPlatformNotificationService::Close( |
| DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| const auto non_persistent_iter = |
| non_persistent_notifications_.find(notification_id); |
| - if (non_persistent_iter == non_persistent_notifications_.end()) { |
| - NotificationEventDispatcher::GetInstance()->DispatchNonPersistentCloseEvent( |
| - notification_id); |
| - non_persistent_notifications_.erase(non_persistent_iter); |
| - } |
| + content::NotificationEventDispatcher::GetInstance() |
|
Peter Beverloo
2017/06/13 22:56:42
nit: drop `content`, we are in that namespace
Miguel Garcia
2017/06/14 09:39:39
Done.
|
| + ->DispatchNonPersistentCloseEvent(notification_id); |
| + non_persistent_notifications_.erase(non_persistent_iter); |
|
Peter Beverloo
2017/06/13 22:56:42
Just call n_p_n_.erase() with |notification_id| if
Miguel Garcia
2017/06/14 09:39:39
Done.
|
| } |
| void MockPlatformNotificationService::ReplaceNotificationIfNeeded( |