summaryrefslogtreecommitdiff
path: root/actions/avatarsettings.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/avatarsettings.php')
-rw-r--r--actions/avatarsettings.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/actions/avatarsettings.php b/actions/avatarsettings.php
index 643c0e567..68c6ce701 100644
--- a/actions/avatarsettings.php
+++ b/actions/avatarsettings.php
@@ -320,7 +320,7 @@ class AvatarsettingsAction extends AccountSettingsAction
$this->serverError(_('Lost our file data.'));
return;
}
-
+
// If image is not being cropped assume pos & dimentions of original
$dest_x = $this->arg('avatar_crop_x') ? $this->arg('avatar_crop_x'):0;
$dest_y = $this->arg('avatar_crop_y') ? $this->arg('avatar_crop_y'):0;
@@ -328,10 +328,10 @@ class AvatarsettingsAction extends AccountSettingsAction
$dest_h = $this->arg('avatar_crop_h') ? $this->arg('avatar_crop_h'):$filedata['height'];
$size = min($dest_w, $dest_h);
$size = ($size > MAX_ORIGINAL) ? MAX_ORIGINAL:$size;
-
+
$user = common_current_user();
$profile = $user->getProfile();
-
+
$imagefile = new ImageFile($user->id, $filedata['filepath']);
$filename = $imagefile->resize($size, $dest_x, $dest_y, $dest_w, $dest_h);