Skip to content

Commit

Permalink
Fixed: issue in redirection using GoToOms button by updating the rege…
Browse files Browse the repository at this point in the history
…x for generating the link(#275)
  • Loading branch information
ymaheshwari1 committed Mar 18, 2024
1 parent 36036e8 commit 775ab06
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { toastController } from "@ionic/vue";
import { translate } from "src";

const goToOms = (token: string, oms: string) => {
const link = (oms.startsWith('http') ? oms.replace(/api\/?/, "") : `https://${oms}.hotwax.io/`) + `commerce/control/main?token=${token}`
const link = (oms.startsWith('http') ? oms.replace(/\/api\/?|\/$/, "") : `https://${oms}.hotwax.io`) + `/commerce/control/main?token=${token}`

window.open(link, '_blank', 'noopener, noreferrer')
}
Expand Down

0 comments on commit 775ab06

Please sign in to comment.