From bef3aca0eee3ec3a6e1ca7371350c423a0c35fa8 Mon Sep 17 00:00:00 2001 From: "scott%scott-macgregor.org" Date: Tue, 9 Nov 2004 04:44:39 +0000 Subject: [PATCH] Bug #260561 --> RSS feeds don't get added if URL contains trailing whitespace git-svn-id: svn://10.0.0.236/trunk@165149 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/mail/extensions/newsblog/content/feed-properties.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/mozilla/mail/extensions/newsblog/content/feed-properties.js b/mozilla/mail/extensions/newsblog/content/feed-properties.js index 92152454dbd..15a107ebbaf 100644 --- a/mozilla/mail/extensions/newsblog/content/feed-properties.js +++ b/mozilla/mail/extensions/newsblog/content/feed-properties.js @@ -54,7 +54,11 @@ function onLoad() function onOk() { - window.arguments[0].feedLocation = document.getElementById('feedLocation').value; + var feedLocation = document.getElementById('feedLocation').value; + // trim leading and trailing white space from the url + feedLocation = feedLocation.replace( /^\s+/, "").replace( /\s+$/, ""); + + window.arguments[0].feedLocation = feedLocation; window.arguments[0].folderURI = document.getElementById('selectFolder').value; window.arguments[0].quickMode = document.getElementById('quickMode').checked; window.arguments[0].result = true;