You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "elharo (via GitHub)" <gi...@apache.org> on 2026/07/03 14:02:17 UTC
[I] Wrong constant in error message in ResourceRef constructor [maven-ear-plugin]
elharo opened a new issue, #520:
URL: https://github.com/apache/maven-ear-plugin/issues/520
## Description
In `ResourceRef.java:74-75`, the error message uses the wrong constant:
```java
} else if ((type == null || type.isEmpty()) && (auth == null || auth.isEmpty())) {
throw new IllegalArgumentException(RESOURCE_TYPE + " in " + RESOURCE_REF_NAME + " element cannot be null ");
}
```
`RESOURCE_REF_NAME` is `"res-ref-name"` but the message should refer to the `"resource-ref"` element. The correct constant would be `RESOURCE_REF` which is `"resource-ref"`.
## Expected behavior
Use `RESOURCE_REF` instead of `RESOURCE_REF_NAME`:
```java
throw new IllegalArgumentException(RESOURCE_TYPE + " in " + RESOURCE_REF + " element cannot be null");
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Wrong constant in error message in ResourceRef constructor [maven-ear-plugin]
Posted by "elharo (via GitHub)" <gi...@apache.org>.
elharo closed issue #520: Wrong constant in error message in ResourceRef constructor
URL: https://github.com/apache/maven-ear-plugin/issues/520
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@maven.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org