I'm trying to implement Firebase Cloud Messaging in a web-app (with Polymer and a service-worker and using the custom-sw of the SDK).
It is working great (on both desktop and android) but when the user click on the notification it is always opening the click_action
in a new tab even if a tab of the same origin is opened (but not focused).
click_action = "https://example.firebaseapp.com/demo/command"
Url of inactive tab = "https://example.firebaseapp.com/demo"
It seems that the getWindowClient_
method of the FCM SDK is not parsing correctly the URL of active clients and so can't call focus()
on the inactive tab.
Any idea how to resolve this ?