You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by GitBox <gi...@apache.org> on 2019/11/25 15:06:42 UTC

[GitHub] [commons-collections] garydgregory commented on a change in pull request #118: Fixed the typo and deal the NPE with Objects.requireNonNull

garydgregory commented on a change in pull request #118: Fixed the typo and deal the NPE with Objects.requireNonNull 
URL: https://github.com/apache/commons-collections/pull/118#discussion_r350237259
 
 

 ##########
 File path: src/main/java/org/apache/commons/collections4/list/AbstractLinkedList.java
 ##########
 @@ -514,6 +515,8 @@ protected void addNodeAfter(final Node<E> node, final E value) {
      * @throws NullPointerException if either node is null
      */
     protected void addNode(final Node<E> nodeToInsert, final Node<E> insertBeforeNode) {
+        Objects.requireNonNull(nodeToInsert,"The new node on insert must not be null.");
 
 Review comment:
   Please add a space after the comma.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services