Skip to content

Conversation

@deepsource-autofix
Copy link
Contributor

This PR refactors the authentication check, replacing a null-coalescing default with an explicit boolean comparison for improved readability and intent.

  • Consider using the equality operators when evaluating bool?: The principal?.Identity?.IsAuthenticated property was previously unwrapped with ?? false, potentially conflating null and false values. By switching to == true, the code now explicitly returns true only when the property is true, while treating null or false as false.

This Autofix was generated by AI. Please review the change before merging.

This PR refactors the authentication check, replacing a null-coalescing default with an explicit boolean comparison for improved readability and intent.

- Consider using the equality operators when evaluating `bool?`: The `principal?.Identity?.IsAuthenticated` property was previously unwrapped with `?? false`, potentially conflating `null` and `false` values. By switching to `== true`, the code now explicitly returns true only when the property is true, while treating null or false as false.

> This Autofix was generated by AI. Please review the change before merging.
This commit fixes the style issues introduced in ce22777 according to the output
from dotnet-format.

Details: #371
@deepsource-io
Copy link

deepsource-io bot commented Sep 20, 2025

Here's the code health analysis summary for commits a6e02eb..698fce5. View details on DeepSource ↗.

Analysis Summary

AnalyzerStatusSummaryLink
DeepSource SQL LogoSQL✅ SuccessView Check ↗
DeepSource Docker LogoDocker✅ SuccessView Check ↗
DeepSource C# LogoC#✅ Success
🎯 1 occurence resolved
View Check ↗

💡 If you’re a repository administrator, you can configure the quality gates from the settings.

@StuartFerguson StuartFerguson merged commit bce4f40 into master Sep 20, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants