fix a bug in Ox.URL where URLs of the form '/=foo' would not be parsed correctly
This commit is contained in:
parent
f2490fe771
commit
f1bfb545f1
1 changed files with 1 additions and 2 deletions
|
@ -313,7 +313,7 @@ Ox.URL = function(options) {
|
||||||
|| Ox.getPositionById(self.options.findKeys, condition.key) == -1
|
|| Ox.getPositionById(self.options.findKeys, condition.key) == -1
|
||||||
) {
|
) {
|
||||||
// missing operator or unknown key
|
// missing operator or unknown key
|
||||||
condition = {key: '*', value: str, operator: '='};
|
condition = {key: '*', value: condition.value, operator: '='};
|
||||||
}
|
}
|
||||||
if (['=', '!='].indexOf(condition.operator) > -1) {
|
if (['=', '!='].indexOf(condition.operator) > -1) {
|
||||||
if (condition.value[0] == '*') {
|
if (condition.value[0] == '*') {
|
||||||
|
@ -415,7 +415,6 @@ Ox.URL = function(options) {
|
||||||
}
|
}
|
||||||
|
|
||||||
function parseURL(str, callback) {
|
function parseURL(str, callback) {
|
||||||
Ox.print('pU', str)
|
|
||||||
// fixme: removing trailing slash makes it impossible to search for '/'
|
// fixme: removing trailing slash makes it impossible to search for '/'
|
||||||
str = str.replace(/(^\/|\/$)/g, '');
|
str = str.replace(/(^\/|\/$)/g, '');
|
||||||
var parts = str.split('/'),
|
var parts = str.split('/'),
|
||||||
|
|
Loading…
Reference in a new issue