Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fikser bug der variabel i søknads-api-tekstene ikke ble erstattet #760

Merged
merged 4 commits into from
Feb 23, 2021

Conversation

idaons
Copy link
Contributor

@idaons idaons commented Feb 22, 2021

No description provided.

@idaons idaons requested a review from a team as a code owner February 22, 2021 10:55
export const replaceNavkontor = (text: string, valgtEnhetsNavn?: string) => {
// Hvis ikke valgtEnhetsNavn finnes, erstattes søkestrengen med capture-gruppa ([\w\s-]*)
// som er 1 eller fler bokstaver, whitespace eller '-', feks "NAV-kontoret ditt" fra søknads-api-tekstene
return text.replaceAll(/{navkontor:([\w\s-]*)}/g, valgtEnhetsNavn ? valgtEnhetsNavn : "$1");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.replaceAll er tydeligvis ikke en funksjon 🤔
Fungerer denne i alle nettlesere?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Byttet til replace! Trodde først det ikke funket, men nå ser det ut som det funket likevel. Skal test i labs for sikkerhetsskyld, må bare få bygget igjennom først :)

(ble litt tidlig PR, hadde tenkt å lage draft, men fikk det ikke til i ettertid..)

@idaons
Copy link
Contributor Author

idaons commented Feb 22, 2021

Bygg feiler, sies at det skulle ha kommet en fix på sikkerhetshullet i helgen facebook/create-react-app#10412, så ser an litt.

@idaons idaons marked this pull request as draft February 23, 2021 07:44
@nais-deploy nais-deploy bot temporarily deployed to labs-gcp:teamdigisos February 23, 2021 07:47 Inactive
@nais-deploy nais-deploy bot temporarily deployed to dev-sbs:teamdigisos February 23, 2021 08:46 Inactive
@sonarcloud
Copy link

sonarcloud bot commented Feb 23, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@idaons idaons marked this pull request as ready for review February 23, 2021 09:00
@idaons idaons requested a review from siljee February 23, 2021 10:27
@idaons idaons merged commit 09ff9bf into master Feb 23, 2021
@idaons idaons deleted the bugfix/modal-regex branch February 23, 2021 11:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants