Remove the Handlebars helpers 'mkws-best-url' and 'mkws-other-urls'.
The relevant logic is now in the widget itself.
I hope this will make Jason happy.
});
-var _urlRegexp = /^(https?:)?\/\//;
-Handlebars.registerHelper('mkws-best-url', function(items) {
- for (var i in items) {
- var item = items[i]
- if (item.match(_urlRegexp)) {
- mkws.debug("'" + item + "' *is* a URL");
- return item;
- }
- mkws.debug("'" + item + "' is not a URL");
- }
- return "";
-});
-Handlebars.registerHelper('mkws-other-urls', function(items) {
- var res = [];
- for (var i in items) {
- var item = items[i]
- if (item.match(_urlRegexp)) {
- res.push(item);
- }
- }
- return res;
-});
-
-
-
Handlebars.registerHelper('mkws-commaList', function(items, options) {
var out = "";