Skip to content

Comments

Fix null exceptions when requesting specific content trough the backoffice APIs#17846

Merged
nikolajlauridsen merged 1 commit intov13/devfrom
v13/bugfix/null-user-in-authHandling
Jan 7, 2025
Merged

Fix null exceptions when requesting specific content trough the backoffice APIs#17846
nikolajlauridsen merged 1 commit intov13/devfrom
v13/bugfix/null-user-in-authHandling

Conversation

@Migaroez
Copy link
Contributor

Fixes #17701

Description

As the ContentPermissions.CheckPermissions() implicetly throws an error, I chose to fix the null ref in the consuming handlers as from a AuthorizationHandler it makes sense that we have a logged in user before checking it's permissions.

Testing

Check the steps in the linked issue and keep in mind that this fix delivers a result that is in line with other Authorization Handlers failing in any way.

@nikolajlauridsen nikolajlauridsen merged commit c96dc7e into v13/dev Jan 7, 2025
@nikolajlauridsen nikolajlauridsen deleted the v13/bugfix/null-user-in-authHandling branch January 7, 2025 13:52
@nikolajlauridsen
Copy link
Contributor

Cherry picked to 13.6

andr317c added a commit that referenced this pull request Jan 14, 2025
* Added timeouts

* Nullcheck user in Content permission handlers (#17846)

---------

Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: Niels Lyngsø <nsl@umbraco.dk>
Migaroez added a commit that referenced this pull request Jan 14, 2025
* Added timeouts

* Nullcheck user in Content permission handlers (#17846)

---------

Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: Niels Lyngsø <nsl@umbraco.dk>
Migaroez added a commit that referenced this pull request Jan 14, 2025
* Conditionally render error details and make sure something is rendered

* V13 QA updated locator for failing E2E test (#17825)

* Added timeouts

* Nullcheck user in Content permission handlers (#17846)

---------

Co-authored-by: Sven Geusens <sge@umbraco.dk>
Co-authored-by: Niels Lyngsø <nsl@umbraco.dk>

---------

Co-authored-by: Andreas Zerbst <73799582+andr317c@users.noreply.github.com>
Co-authored-by: Niels Lyngsø <nsl@umbraco.dk>
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.

2 participants