mirror of
https://github.com/sasjs/server.git
synced 2025-12-10 11:24:35 +00:00
Merge pull request #343 from sasjs/quick-fix
fix: add location.pathname to location.origin conditionally
This commit is contained in:
@@ -31,7 +31,10 @@ const RunMenu = ({
|
||||
handleRunBtnClick
|
||||
}: RunMenuProps) => {
|
||||
const launchProgram = () => {
|
||||
const baseUrl = window.location.origin + window.location.pathname
|
||||
const pathName =
|
||||
window.location.pathname === '/' ? '' : window.location.pathname
|
||||
const baseUrl = window.location.origin + pathName
|
||||
|
||||
window.open(`${baseUrl}/SASjsApi/stp/execute?_program=${selectedFilePath}`)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user