Convert inline profile image transforms to new transformations
Summary: Ref T7707. Fixes T7879. Fixes T4406. When creating profile images: - Use the new transforms; - mark them as "profile" images so they're forced to the most-open policies. Test Plan: - Set restrictive default file policies. - Changed profile picture, project pictures, etc. Verified they were visible to logged-out users. - Registered via OAuth. - Updated a Conpherence thread image. - Browsed around looking for profile images, fixed sizing on everything I could find. Reviewers: chad, btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T7879, T7707, T4406 Differential Revision: https://secure.phabricator.com/D12821
This commit is contained in:
@@ -604,17 +604,9 @@ final class PhabricatorAuthRegisterController
|
||||
return null;
|
||||
}
|
||||
|
||||
try {
|
||||
$xformer = new PhabricatorImageTransformer();
|
||||
return $xformer->executeProfileTransform(
|
||||
$file,
|
||||
$width = 50,
|
||||
$min_height = 50,
|
||||
$max_height = 50);
|
||||
} catch (Exception $ex) {
|
||||
phlog($ex);
|
||||
return null;
|
||||
}
|
||||
$xform = PhabricatorFileTransform::getTransformByKey(
|
||||
PhabricatorFileThumbnailTransform::TRANSFORM_PROFILE);
|
||||
return $xform->executeTransform($file);
|
||||
}
|
||||
|
||||
protected function renderError($message) {
|
||||
|
||||
Reference in New Issue
Block a user