(function(n){"use strict";var i=navigator.serviceWorker;if(!i)return this.UpUp=null,n;var t={"service-worker-url":"/upup.sw.min.js","registration-options":{}},r=!1,u="font-weight: bold; color: #00f;";this.UpUp={start:function(n){this.addSettings(n);i.register(t["service-worker-url"],t["registration-options"]).then(function(n){r&&console.log("Service worker registration successful with scope: %c"+n.scope,u);(n.installing||i.controller||n.active).postMessage({action:"set-settings",settings:t})}).catch(function(n){r&&console.log("Service worker registration failed: %c"+n,u)})},addSettings:function(i){"string"==typeof(i=i||{})&&(i={content:i});["content","content-url","assets","service-worker-url","cache-version"].forEach(function(r){i[r]!==n&&(t[r]=i[r])});i.scope!==n&&(t["registration-options"].scope=i.scope)},debug:function(n){r=!(0<arguments.length)||!!n}}}).call(this)