From 6d1b570e73ebc275ee7a5e4a09715770e8ea9804 Mon Sep 17 00:00:00 2001 From: tmeissner Date: Mon, 25 Feb 2013 18:33:06 +0100 Subject: [PATCH] fixed bug in regexp (match too long, fixed by +? for shortest match) of replace call to remove parentheses --- scripts/haltestellen.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/haltestellen.js b/scripts/haltestellen.js index 9e42530..18bb1cb 100644 --- a/scripts/haltestellen.js +++ b/scripts/haltestellen.js @@ -78,7 +78,7 @@ function ajaxCall(dataUrl, outputElement, callback) { console.log("received data: " + data); data = data.replace(/\],\[/gi, '#'); - data = data.replace(/\(.+\)/gi, ''); + data = data.replace(/\(.+?\)/gi, ''); data = data.slice(2,-2).split("#"); console.log("parsed data: " + data);