From: Brion Vibber Date: Fri, 19 Mar 2010 00:18:01 +0000 (-0700) Subject: Handle "forgot to upload an avatar on avatarsettings" a little more gracefully. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=01a1e882afeb78542b02e4643c5d8a2fa50c2206;p=quix0rs-gnu-social.git Handle "forgot to upload an avatar on avatarsettings" a little more gracefully. --- diff --git a/actions/avatarsettings.php b/actions/avatarsettings.php index 6a7398746a..d4ea11cb7e 100644 --- a/actions/avatarsettings.php +++ b/actions/avatarsettings.php @@ -301,6 +301,10 @@ class AvatarsettingsAction extends AccountSettingsAction $this->showForm($e->getMessage()); return; } + if ($imagefile === null) { + $this->showForm(_('No file uploaded.')); + return; + } $cur = common_current_user();