Recent contacts view on home screen

Hi guys, I've added some logic to create the recent contacts view. It took me a while and a lot of searching to create this functionality. With this branch, recent contacts are parsed in home.js, and listed out in descending order by the number of occurrence (the more common a name appears on screen, the higher it is on the list).
The number of contacts is limited to 5 and the user's own name is omitted from the list.

 However, there is still a part where I still don't understand (I know, I coded this up O_o). Particularly between line 124 to 134 of home.js. 
Hopefully y'all can shed some light on this and review the PR in the meantime!

Cheers! :smiley: 
Ahh, so userCounts are being used to sort people's names in descending order of appearance!  This definitely works, but perhaps you could move the counting logic to here.  If you have an array of unique `<div class="name"` elements called uniqueArray, maybe you could do something like:
<pre>
uniqueArray.sort(function(a,b){
    return $("[data-id=' " + a.dataset.id + ']").length - $("[data-id=' " + b.dataset.id + ']").length;
});
</pre>
?  That way, you wouldn't need to calculate the userCounts by incrementing, but instead, use jQuery's $ to get a list of all elements with that match the data-id, and then count them by taking the length of the array.