each on array of two objects results in three objects

each on array of two objects results in three objects

I'm trying to iterate through an array and clone and append an element to a div element for each item in the array.
Everything is working except that when it's more than one element I get som unexpected results.
The array contains two element's and I've checked that the each loop only runs two times, but for some reason I get a third element in the result (as you can see from the image). The two first are correct, but why am I getting a third element?



Am I using clone() and append() correctly?

each:
  1. let items = $(contentWrap).find(".lc-rating-modal-review-items-wrap");
  2. $(items).empty();
  3. $.each(data.items, function (index, review) {
  4.     let item = GenerateReviewItem(review);
  5.     $(item).appendTo(items);
  6. });

GenerateReviewItem:
  1. function GenerateReviewItem(review) {
  2.     let result = $(wrap).find(".lc-rating-review-item-template").clone();
  3.     $(result).find(".lc-rating-review-item-template-date").html(review.dateFormated);
  4.     $(result).find(".lc-rating-review-item-body-wrap").html(review.review);
  5.     $(result).find(".lc-rating-review-item-template-stars-rating-label").html("(" + review.rating + ")");
  6.     $(result).find(".lc-rating-review-item-template-star").each(function (index, star) {
  7.         if (review.rating >= (index + 1)) {
  8.             $(star).removeClass("fa-star-o").addClass("fa-star");
  9.         }
  10.     });             
  11.     return result;
  12. }

Html Im trying to clone:
  1. <div style="display:none;">
  2.     <div class="lc-rating-review-item-template">
  3.         <div class="lc-rating-review-item-header-wrap">
  4.             <div class="lc-rating-review-item-template-stars-wrap">
  5.                 <div>
  6.                     <i class="fa fa-star-o lc-rating-review-item-template-star" aria-hidden="true"></i>
  7.                 </div>
  8.                 <div>
  9.                     <i class="fa fa-star-o lc-rating-review-item-template-star" aria-hidden="true"></i>
  10.                 </div>
  11.                 <div>
  12.                     <i class="fa fa-star-o lc-rating-review-item-template-star" aria-hidden="true"></i>
  13.                 </div>
  14.                 <div>
  15.                     <i class="fa fa-star-o lc-rating-review-item-template-star" aria-hidden="true"></i>
  16.                 </div>
  17.                 <div>
  18.                     <i class="fa fa-star-o lc-rating-review-item-template-star" aria-hidden="true"></i>
  19.                 </div>
  20.                 <div>
  21.                     <span class="lc-rating-review-item-template-stars-rating-label"></span>
  22.                 </div>
  23.             </div>
  24.             <div style="text-align:right;">
  25.                 <span class="lc-rating-review-item-template-date"></span>
  26.             </div>
  27.         </div>
  28.         <div class="lc-rating-review-item-body-wrap"></div>
  29.     </div>
  30. </div>