summaryrefslogtreecommitdiff
path: root/actions/avatarsettings.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2009-02-04 07:25:36 -0500
committerEvan Prodromou <evan@controlyourself.ca>2009-02-04 07:25:36 -0500
commit355d438ceebc35ae98593a9a80a817ccaa441643 (patch)
treee1444f6994069f10a49f54f113d435cf329a09b6 /actions/avatarsettings.php
parentaafb73755e7fbeb1b0e4198ce727c3ee1c8a5c94 (diff)
parent3b6d2653fb82271771d5889e63275666409b0eb1 (diff)
Merge branch '0.7.x' of git://gitorious.org/laconica/meitar into meitar/0.7.x
Diffstat (limited to 'actions/avatarsettings.php')
-rw-r--r--actions/avatarsettings.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/actions/avatarsettings.php b/actions/avatarsettings.php
index 19f53b882..3029b0621 100644
--- a/actions/avatarsettings.php
+++ b/actions/avatarsettings.php
@@ -316,11 +316,6 @@ class AvatarsettingsAction extends AccountSettingsAction
$profile = $user->getProfile();
- $x = $this->arg('avatar_crop_x');
- $y = $this->arg('avatar_crop_y');
- $w = $this->arg('avatar_crop_w');
- $h = $this->arg('avatar_crop_h');
-
$filedata = $_SESSION['FILEDATA'];
if (!$filedata) {
@@ -328,6 +323,11 @@ class AvatarsettingsAction extends AccountSettingsAction
return;
}
+ $x = $this->arg('avatar_crop_x');
+ $y = $this->arg('avatar_crop_y');
+ $w = ($this->arg('avatar_crop_w')) ? $this->arg('avatar_crop_w') : $filedata['width'];
+ $h = ($this->arg('avatar_crop_h')) ? $this->arg('avatar_crop_h') : $filedata['height'];
+
$filepath = common_avatar_path($filedata['filename']);
if (!file_exists($filepath)) {