-
-
Notifications
You must be signed in to change notification settings - Fork 264
fix: fixed all sonar cloud issue #1884
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
base: master
Are you sure you want to change the base?
fix: fixed all sonar cloud issue #1884
Conversation
- use 'node:' prefix for built-in modules - replace if-assignment with nullish coalescing (??=) - use String#replaceAll and String.raw in wildcardToRegex
Use RegExp.exec() instead of String.match() in convertGitHubWebUrl Remove unnecessary try/catch from isValidGitHubBlobUrl Refactor read function in HTTP resolver to reduce cognitive complexity from 16 to 15
🦋 Changeset detectedLatest commit: 0713671 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Changeset has been generated for this PR as part of auto-changeset workflow.Please review the changeset before merging the PR.If you are a maintainer or the author of the PR, you can change the changeset by clicking here Tip If you don't want auto-changeset to run on this PR, you can add the label |
|
Hey, @AayushSaini101 when you have some time, please check the PR. Thanks! |
|
Hey @Shurtu-gal , @AayushSaini101 |
…satisfy Sonar rule S7780
chore: add changeset for PR asyncapi#1884 fix(config): replace unsafe regex literal with safe escapePattern to satisfy Sonar rule S7780
…satisfy Sonar rule S7780
|
|
Ready for review now... |



Description
This PR addresses all SonarCloud-reported issues. Changes include:
updates: Made public static fields
readonlyinsrc/apps/cli/commands/config/auth/add.tsfix: make static properties readonly to resolve SonarCloud issue S1444 #1883Node built-in module imports: Use
'node:'prefix for built-in modulesNullish coalescing operator: Replace
if-assignment with??=wildcardToRegeximprovements: UseString#replaceAll()andString.rawGitHub URL handling and HTTP resolver:
RegExp.exec()instead ofString.match()inconvertGitHubWebUrltry/catchfromisValidGitHubBlobUrlreadfunction in HTTP resolver to reduce cognitive complexity from 16 to 15Related issue(s)
This Issue is related to #1881