When starting Campfire locally, following error occurs, visible in browser console:
Uncaught (in promise) SecurityError: Failed to get a ServiceWorkerRegistration: The origin of the provided documentURL ('null') does not match the current origin ('http://localhost:3000')
Seems that the issue is mismatch of arguments in getRegistration() call.
The argument should be origin (protocol + host), but window.location.host is passed, which is only host without protocol.
I created PR #49
When starting Campfire locally, following error occurs, visible in browser console:
Uncaught (in promise) SecurityError: Failed to get a ServiceWorkerRegistration: The origin of the provided documentURL ('null') does not match the current origin ('http://localhost:3000')Seems that the issue is mismatch of arguments in getRegistration() call.
The argument should be origin (protocol + host), but
window.location.hostis passed, which is only host without protocol.I created PR #49