mirror of
https://github.com/Mibew/mibew.git
synced 2025-03-03 10:28:32 +03:00
Do not use MIBEW_WEB_ROOT in AvatarController
This commit is contained in:
parent
e6b9635e22
commit
34a8a2eee4
@ -123,7 +123,7 @@ class AvatarController extends AbstractController
|
|||||||
// Move uploaded file to avatar directory
|
// Move uploaded file to avatar directory
|
||||||
try {
|
try {
|
||||||
$file->move($avatar_local_dir, $new_file_name);
|
$file->move($avatar_local_dir, $new_file_name);
|
||||||
$avatar = MIBEW_WEB_ROOT . "/files/avatar/$new_file_name";
|
$avatar = $request->getBasePath() . "/files/avatar/" . $new_file_name;
|
||||||
} catch (Exception $e) {
|
} catch (Exception $e) {
|
||||||
$errors[] = failed_uploading_file($orig_filename, "Error moving file");
|
$errors[] = failed_uploading_file($orig_filename, "Error moving file");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user