Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
exports.controller = (function() {
var modules = {
versioning: require('versioning').versioning,
session: require('session').session,
sync: require('sync').sync,
ajax: require('ajax').ajax,
webfinger: require('webfinger').webfinger,
oauth: require('oauth').oauth,
couch: require('couch').couch,
button: require('button').button
};
var deadLine;
var working=false;
var intervalTimer;
var options = {
onChange: function(key, oldValue, newValue) {
console.log('item "'+key+'" changed from "'+oldValue+'" to "'+newValue+'"');
console.log('WARNING: Please configure an onChange function! Forcing full page refresh instead');
window.location = '';
},
category: location.host.replace('.', '_')
};
function onError(str) {
alert(str);