Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WFCORE-6697: fix resource location check #5869

Merged
merged 1 commit into from
Feb 21, 2024
Merged

Conversation

michpetrov
Copy link
Contributor

Issue: WFCORE-6697

The operation is deprecated so I don't know if we want to fix this.

@github-actions github-actions bot added the deps-ok Dependencies have been checked, and there are no significant changes label Feb 16, 2024
@@ -211,7 +211,7 @@ private static List<String> findResourcePaths(String moduleName) throws ModuleLo

List<String> result = new LinkedList<>();
for (ResourceLoaderInfo rl : loader.getResourceLoaders(moduleName)){
if (rl.getLocation() != null) {
if (!rl.getLocation().equals("null")) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ResourceLoaderInfo constructor and getLocation() method don't say too much about the nullity returned in case there is no location, but in any case, checking for a null value before comparing with "null" string would make it more resilient to JBoss Modules changes.

What do you think @michpetrov ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The initialization was changed to avoid dealing with null values - jboss-modules/jboss-modules@a357326 - so I don't think it's likely, but sure I'll change it.

@yersan yersan added the ready-for-merge This PR is ready to be merged and fulfills all requirements label Feb 21, 2024
@yersan yersan merged commit 6b9df9f into wildfly:main Feb 21, 2024
12 checks passed
@yersan
Copy link
Collaborator

yersan commented Feb 21, 2024

Thanks @michpetrov

@michpetrov michpetrov deleted the wfcore-6697 branch February 21, 2024 13:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deps-ok Dependencies have been checked, and there are no significant changes ready-for-merge This PR is ready to be merged and fulfills all requirements
Projects
None yet
2 participants