disable avatar loading on public guest page

This commit is contained in:
Jörn Friedrich Dreyer 2013-09-17 19:25:03 +02:00
parent 2e79aab0ce
commit 342a420eba
1 changed files with 5 additions and 3 deletions

View File

@ -1,7 +1,9 @@
$(document).ready(function(){
$('#header .avatardiv').avatar(OC.currentUser, 32);
// Personal settings
$('#avatar .avatardiv').avatar(OC.currentUser, 128);
if (OC.currentUser) {
$('#header .avatardiv').avatar(OC.currentUser, 32);
// Personal settings
$('#avatar .avatardiv').avatar(OC.currentUser, 128);
}
// User settings
$.each($('td.avatar .avatardiv'), function(i, element) {
$(element).avatar($(element).parent().parent().data('uid'), 32);