I receive a 'Uncaught TypeError: Cannot read property 'removeChild' of null' error even though my unordered list works fine
<p>My first time asking a question on here so apologies if I'm missing information. I have the following vanillaJS and receive the Cannot read property 'removeChild'  of null error. The error occurs in the console when I click the 'remove' icon of any list item EXCEPT the last one in the list. However the item clicked is still removed as it should be. Should I be concerned about this error? If so how do I fix it?</p>

<p>I've only been testing this on Chrome as well, I know addEventListener doesn't work on older IE but I'm just trying to get this working on one browser first. Thanks!</p>

<p><a href="https://jsfiddle.net/L5vwdob5/" rel="nofollow">https://jsfiddle.net/L5vwdob5/</a></p>

<p>JavaScript:</p>

<pre><code>    // Variable for my delete buttons
    var getRid = document.getElementsByClassName('remove-icon');

    // Variable for my add item button
    var addListItem = document.getElementById('add-more');

    /* Add item event listener and creation of new li with required css class properties, input field, and remove icon*/
    addListItem.addEventListener('click', function(){
      var u = document.getElementById('full-item-list');
      var l = document.createElement('li');
      var elinput = document.createElement('input');
      var icon = document.createElement('img');
      elinput.setAttribute('type', 'text');
      elinput.setAttribute('class', 'li-input');
      elinput.setAttribute('placeholder', 'Enter item here');
      l.setAttribute('class', 'list-item');
      icon.setAttribute('class', 'remove-icon');
      icon.setAttribute('src', 'delete.png');
      l.appendChild(elinput);
      l.appendChild(icon);
      u.appendChild(l);
    //Called to update number of remove icons
      updateItems();
    });

    // Add event listener to 'remove-icon' to new items created in list
    function updateItems() {
      for (var i = 0; i &lt; getRid.length; i++){
        getRid[i].addEventListener('click', function(e) {
          thaticon(e);
        }, false);
      }
    }

    // Call function so first item in list can be deleted on page load
    updateItems();



    // Function to remove items
    function thaticon(e) {
      var el = e.target;
      var elListItem= el.parentNode;
      elFullList = elListItem.parentNode;
      elFullList.removeChild(elListItem);
    }
</code></pre>