Regression: Cover photos being stored in cloud root instead of "Cover Photos" folder. Ditto for Profile Photos.

This commit is contained in:
nobody 2022-02-24 00:54:16 -08:00
parent 4213e116e9
commit 4b4f24057b

View file

@ -687,7 +687,7 @@ function attach_store($channel, $observer_hash, $options = '', $arr = null)
$pathname = '';
// If we were called from the Photos module there is a slightly different mechanism
// for setting the parent path than if we were called from the Files (cloud) module.
@ -707,6 +707,11 @@ function attach_store($channel, $observer_hash, $options = '', $arr = null)
$pathname = filepath_macro($album);
}
}
elseif ($album && !$newalbum) {
// We can land here from the profile_photo and cover_photo modules.
// Just use the album provided.
$pathname = filepath_macro($album);
}
if (! $pathname) {
$pathname = filepath_macro($upload_path);