junichi11 commented on a change in pull request #2250:
URL: https://github.com/apache/netbeans/pull/2250#discussion_r454983531
##########
File path:
php/php.api.phpmodule/src/org/netbeans/modules/php/api/validation/ValidationResult.java
##########
@@ -80,6 +81,20 @@ public boolean hasErrors() {
return new ArrayList<>(errors);
}
+ /**
+ * Get the first error.
+ *
+ * @return the first error.
+ * @since 2.72
+ */
+ @CheckForNull
+ public Message getFirstError() {
+ if (hasErrors()) {
+ return errors.get(0);
+ }
+ return null;
+ }
Review comment:
Makes sense. I agree with you. I'll keep this. Thanks a lot!
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists