mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-09-20 15:37:46 +03:00
URI encode parameter values
Previously the path to open would not open properly if it contained a '&' character since the character was not encoded and would cause the parameter parsing to stop at the first '&'.
This commit is contained in:
parent
7f6e5e2e52
commit
b89eb07c6e
@ -12,8 +12,10 @@ class AtomWindow
|
||||
@browserWindow = new BrowserWindow show: false, title: 'Atom'
|
||||
@handleEvents()
|
||||
|
||||
url = "file://#{resourcePath}/static/index.html#bootstrapScript=#{bootstrapScript}&resourcePath=#{resourcePath}"
|
||||
url += "&pathToOpen=#{@pathToOpen}" if @pathToOpen
|
||||
url = "file://#{resourcePath}/static/index.html#"
|
||||
url += "bootstrapScript=#{encodeURIComponent(bootstrapScript)}"
|
||||
url += "&resourcePath=#{encodeURIComponent(resourcePath)}"
|
||||
url += "&pathToOpen=#{encodeURIComponent(@pathToOpen)}" if @pathToOpen
|
||||
url += '&exitWhenDone=1' if exitWhenDone
|
||||
|
||||
@browserWindow.loadUrl url
|
||||
|
Loading…
Reference in New Issue
Block a user