Merge branch '4.1' into 4.2

This commit is contained in:
github-actions 2024-03-23 12:28:34 +00:00
commit 984bf3abd1

View File

@ -40,6 +40,10 @@ class BlogMemberExtension extends DataExtension
'BlogProfileImage' => Image::class 'BlogProfileImage' => Image::class
]; ];
private static array $owns = [
'BlogProfileImage',
];
/** /**
* @var array * @var array
*/ */
@ -64,11 +68,6 @@ class BlogMemberExtension extends DataExtension
$this->owner->URLSegment = preg_replace('/-[0-9]+$/', '', $this->owner->URLSegment ?? '') . '-' . $count; $this->owner->URLSegment = preg_replace('/-[0-9]+$/', '', $this->owner->URLSegment ?? '') . '-' . $count;
$count++; $count++;
} }
// Auto publish profile images
if ($this->owner->BlogProfileImage() && $this->owner->BlogProfileImage()->exists()) {
$this->owner->BlogProfileImage()->publishSingle();
}
} }
/** /**