Branch: refs/heads/backport/stable-18.6.x/misc-sonar-npe Home: https://github.com/xwiki/xwiki-platform Commit: bcd0bfbe24c64ffd4ef9c8ef816247369f477ae9 https://github.com/xwiki/xwiki-platform/commit/bcd0bfbe24c64ffd4ef9c8ef81624... Author: Vincent Massol <[email protected]> Date: 2026-07-23 (Thu, 23 Jul 2026) Changed paths: M xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/doc/XWikiDocument.java M xwiki-platform-core/xwiki-platform-oldcore/src/main/java/com/xpn/xwiki/pdf/impl/FileSystemURLFactory.java M xwiki-platform-core/xwiki-platform-wysiwyg/xwiki-platform-wysiwyg-api/src/main/java/org/xwiki/wysiwyg/script/WysiwygEditorScriptService.java Log Message: ----------- [Misc] Fix additional SonarQube-reported NPE risks blocking the quality gate * FileSystemURLFactory: instead of null-checking the file mapping at each call site, make getFileMapping() lazily create and store the mapping in the context, so it's always non-null and callers' mutations still persist. * WysiwygEditorScriptService: handle the null source reference in a single place (the 4-arg overload) rather than short-circuiting in the deprecated 2-arg overload. Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]> (cherry picked from commit d33553c3cc47461cb9fc0d3a95b6b2369667c562) To unsubscribe from these emails, change your notification settings at https://github.com/xwiki/xwiki-platform/settings/notifications