オブジェクトの最大高さを教えてくれるこのスニペットを見つけました。正しく機能するように変更できるものはありますか?
function thisHeight(){
return $(this).height();
}
$("#new-deals ul.centerSpace").height(function() {
var dealNameHeight = Math.max.apply(Math, $(this).find(".deal-name").map(thisHeight));
$(".deal-name").css({height: dealNameHeight});
});