summaryrefslogtreecommitdiff
path: root/actions/avatarsettings.php
diff options
context:
space:
mode:
authorZach Copley <zach@status.net>2009-09-25 16:59:51 -0700
committerZach Copley <zach@status.net>2009-09-25 16:59:51 -0700
commitccc7caf932735a5ba245db5df36615b02e0af9e3 (patch)
treed5ed728d8d67e3e327ecccd942a063564da36520 /actions/avatarsettings.php
parentde5ff19713a990af197330dd8e4314de465ffe76 (diff)
parent150cf8c045e8e091a70440d1b833fa19aaf31419 (diff)
Merge branch 'refactor-api' of git@gitorious.org:~zcopley/statusnet/zcopleys-clone into refactor-api
Diffstat (limited to 'actions/avatarsettings.php')
-rw-r--r--actions/avatarsettings.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/actions/avatarsettings.php b/actions/avatarsettings.php
index 02a684b38..ded419dd7 100644
--- a/actions/avatarsettings.php
+++ b/actions/avatarsettings.php
@@ -362,13 +362,13 @@ class AvatarsettingsAction extends AccountSettingsAction
$profile = $user->getProfile();
$avatar = $profile->getOriginalAvatar();
- $avatar->delete();
+ if($avatar) $avatar->delete();
$avatar = $profile->getAvatar(AVATAR_PROFILE_SIZE);
- $avatar->delete();
+ if($avatar) $avatar->delete();
$avatar = $profile->getAvatar(AVATAR_STREAM_SIZE);
- $avatar->delete();
+ if($avatar) $avatar->delete();
$avatar = $profile->getAvatar(AVATAR_MINI_SIZE);
- $avatar->delete();
+ if($avatar) $avatar->delete();
$this->showForm(_('Avatar deleted.'), true);
}