cloudoperators / juno

Monorepo for the Juno modular frontend framework, apps, design system and component library
http://cloudoperators.github.io/juno/
Apache License 2.0
4 stars 0 forks source link

fix(greenhouse): add support_group only if supportGroups exists and is an array #608

Closed ArtieReus closed 2 weeks ago

ArtieReus commented 2 weeks ago

Summary

This PR improves the handling of the support_group key within initialFilters in appProps. Now, support_group is added only when authData.parsed.supportGroups exists and is a valid array. If supportGroups is undefined, null, or not an array, support_group will be omitted from initialFilters, ensuring cleaner and more reliable data handling. Fixes the issue that prevented colleagues without a supportGroups value from accessing Supernova and Doop.

Related task #611

Changes Made

Screenshots (if applicable)

Error when no support group is set to the logged user:

Screenshot 2024-11-14 at 12 06 54

Testing Instructions

  1. npm i
  2. Remove from the Auth Object the supportGroup delete authData.parsed.supportGroups
  3. npx turbo dev --filter @cloudoperators/juno-app-greenhouse

Checklist

changeset-bot[bot] commented 2 weeks ago

🦋 Changeset detected

Latest commit: 5d7de4973cff4e8d79cdd0f46156b7835a6b92cf

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package | Name | Type | | ----------------------------------- | ----- | | @cloudoperators/juno-app-greenhouse | Patch |

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

github-actions[bot] commented 2 weeks ago

PR Preview Action v1.4.8 :---: Preview removed because the pull request was closed. 2024-11-14 13:13 UTC