An empty DQL variable will no longer produce a null pointer exception#100
An empty DQL variable will no longer produce a null pointer exception#100dorian-krefft-dt merged 1 commit intomainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR fixes a null pointer exception that occurred when creating an empty DQL variable using the $type: dql syntax. The fix adds null checking before dereferencing potentially null objects and returns a multiline comment placeholder instead of crashing.
Changes:
- Added null safety checks in
createUnknownElementmethod to prevent NPE - Updated CHANGELOG.md with bug fix and feature notes
- Added
@NotNullannotation to method return type for clarity
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/main/java/pl/thedeem/intellij/dql/psi/DQLElementFactory.java | Added null checks and fallback to multiline comment to prevent NPE when creating empty DQL variables |
| CHANGELOG.md | Documented the bug fix and added UI improvement feature notes |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Qodana for JVMIt seems all right 👌 No new problems were found according to the checks applied 💡 Qodana analysis was run in the pull request mode: only the changed files were checked View the detailed Qodana reportTo be able to view the detailed Qodana report, you can either:
To get - name: 'Qodana Scan'
uses: JetBrains/qodana-action@v2025.3.1
with:
upload-result: trueContact Qodana teamContact us at qodana-support@jetbrains.com
|
No description provided.