mirror of
https://github.com/zero-peak/ZeroOmega.git
synced 2025-02-02 02:58:13 -05:00
Do not modify the update URL if it contains a query string. Fix #1000.
This commit is contained in:
parent
31a39397c3
commit
80b668a47e
@ -6,7 +6,7 @@ ContentTypeRejectedError = OmegaTarget.ContentTypeRejectedError
|
|||||||
xhrWrapper = (args...) ->
|
xhrWrapper = (args...) ->
|
||||||
xhr(args...).catch (err) ->
|
xhr(args...).catch (err) ->
|
||||||
throw err unless err.isOperational
|
throw err unless err.isOperational
|
||||||
if not err.statusCode?
|
if not err.statusCode
|
||||||
throw new OmegaTarget.NetworkError(err)
|
throw new OmegaTarget.NetworkError(err)
|
||||||
if err.statusCode == 404
|
if err.statusCode == 404
|
||||||
throw new OmegaTarget.HttpNotFoundError(err)
|
throw new OmegaTarget.HttpNotFoundError(err)
|
||||||
@ -26,7 +26,7 @@ fetchUrl = (dest_url, opt_bypass_cache, opt_type_hints) ->
|
|||||||
'Unrecognized Content-Type: ' + contentType)
|
'Unrecognized Content-Type: ' + contentType)
|
||||||
return body
|
return body
|
||||||
|
|
||||||
if opt_bypass_cache
|
if opt_bypass_cache and dest_url.indexOf('?') < 0
|
||||||
parsed = Url.parse(dest_url, true)
|
parsed = Url.parse(dest_url, true)
|
||||||
parsed.search = undefined
|
parsed.search = undefined
|
||||||
parsed.query['_'] = Date.now()
|
parsed.query['_'] = Date.now()
|
||||||
|
Loading…
Reference in New Issue
Block a user