gravatar directive doesn't work on angular
Closed this issue · 1 comments
claudyus commented
Hello Lavinjj,
I try to use your gravatar directive and I found a little bug, patch included!
@@ -36,11 +36,11 @@ angular.module('ui-gravatar', ['md5'])
defaultUrl = '404';
}
// construct the tag to insert into the element
var tag = '<img class="gravatar-icon" src="' + (attrs.secure ? 'https://secure' : 'http://www' ) + '.gravatar.com/avatar/' + hash + '?s=' + size + '&r=' + rating + '&d=' + defaultUrl + '" >';
//remove any existing imgs
- $(elm).find(".gravatar-icon").remove();
+ elm.find('img').remove();
// insert the tag into the element
elm.append(tag);
}
});
}};
lavinjj commented
Thanks I'll update it.