Fix JS error for guests

Though we support displaying the page to guests (with a "log In" button), it triggers a js error because there is no avatar there.

![screen shot 2014-04-03 at 5 19 20 pm](https://cloud.githubusercontent.com/assets/9347/2605339/5c7b634a-bb43-11e3-81f5-8fcbc83c5e28.png)

This fixes that error, avoiding to add a useless event if the element does not exists.