code: function handleImageLoad(adElement, adLoadedCallback) {
      var adImage = adElement.querySelector("img");
      if (adImage) {
          (function (adToInsert, adImage) {
              adImage.onload = function () {
                  adLoadedCallback(adToInsert, true);
              };
          })(adElement, adImage);
      } else {
          adLoadedCallback(adElement, false);
      }
  }
docs: Add an event handler to the onload of ad images.
  @param adElement - The HTML element of the advertisement
  @param adLoadedCallback - Callback to execute when ads are loaded