Callback method is not being called when I attach my event to element. The method in question belongs to an object but it seems the way I am calling it the method isn't being called when the click event occurs.
 var myObject = {
     handledrop : function () {
          
         //retrieved created html element
         var elem = document.getElementById("required");
         elem.addEventListener("click", this.deleteFavorite.bind(this), false);
     },
     //this method isn't being called when click event occurs
     deleteFavorite: function (evt) {
        console.log(evt);
     }
 }
What am I doing wrong? How do I pass the right context so that the correct method is called and passed the right context which is event
 
     
     
    