From 794457da75124cd3254674625793f94666ffb799 Mon Sep 17 00:00:00 2001 From: Tobie Langel Date: Thu, 24 Jan 2008 03:02:34 +0000 Subject: [PATCH] Make Ajax.Request#isSameOrigin JavaScript Lint compliant. Backport fix to 1.5.1.2. --- CHANGELOG | 2 ++ src/ajax.js | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG b/CHANGELOG index 3944a7a..282e3f2 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,5 +1,7 @@ *SVN* +* Make Ajax.Request#isSameOrigin JavaScript Lint compliant. [Andrew Dupont] + * Properly serialize form fields with names that collide with built-in JS properties (like "length" or "toString"). Closes #9609. [gryn, kangax] * Make Object.isArray correctly identify arrays created in another frame. Closes #10374. [pointy, Dean Edwards, Andrew Dupont, Tobie Langel] diff --git a/src/ajax.js b/src/ajax.js index a1abed6..e4de8c2 100644 --- a/src/ajax.js +++ b/src/ajax.js @@ -208,7 +208,7 @@ Ajax.Request = Class.create(Ajax.Base, { }, isSameOrigin: function() { - var m = this.url.match(/^\s*https?:\/\/[^/]*/); + var m = this.url.match(/^\s*https?:\/\/[^\/]*/); return !m || (m[0] == '#{protocol}//#{domain}#{port}'.interpolate({ protocol: location.protocol, domain: document.domain,