Skip to content

Commit

Permalink
Merge pull request #628 from cagov/Multi-Language-Phase-2
Browse files Browse the repository at this point in the history
Updated Spanish Help URL
  • Loading branch information
dtodd-edd authored Mar 6, 2024
2 parents 4f89eee + e455ea2 commit f61bf77
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions utils/browser/getUrl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,16 @@ export default function getUrl(linkKey: string, urlPrefixes?: UrlPrefixes, langu
)
const urlPrefixBpo = stripTrailingSlashes(urlPrefixes?.urlPrefixBpo || process.env.URL_PREFIX_BPO)

if (urlPrefixUioDesktop && key.startsWith('uio-desktop') && key !== 'uio-desktop-help-new-claim-es') {
let query = '?l='
const curLanguage = languages.languagelist.find(function (item) {
return item['language-code'] === language
})
if (typeof curLanguage !== 'undefined') {
query += curLanguage?.['ms-culture']
if (urlPrefixUioDesktop && key.startsWith('uio-desktop')) {
let query = ''
if (!key.startsWith('uio-desktop-help-new-claim')) {
query = '?l='
const curLanguage = languages.languagelist.find(function (item) {
return item['language-code'] === language
})
if (typeof curLanguage !== 'undefined') {
query += curLanguage?.['ms-culture']
}
}
return urls[key].replace('uio.edd.ca.gov/UIO', urlPrefixUioDesktop) + query
}
Expand Down

0 comments on commit f61bf77

Please sign in to comment.