Skip to content

Commit

Permalink
Fixed #10499
Browse files Browse the repository at this point in the history
  • Loading branch information
brandonkelly committed Jun 3, 2022
1 parent b9bca47 commit 5412e2b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Expand Up @@ -10,6 +10,9 @@
- Deprecated `craft\services\Users::pruneDeletedField()`. ([#11054](https://github.com/craftcms/cms/discussions/11054))
- Deprecated `craft\services\Volumes::pruneDeletedField()`. ([#11054](https://github.com/craftcms/cms/discussions/11054))

### Fixed
- Fixed an error that could occur when saving an element to a disabled site. ([#10499](https://github.com/craftcms/cms/issues/10499))

## 4.0.4 - 2022-06-03

### Added
Expand Down
2 changes: 1 addition & 1 deletion src/base/Element.php
Expand Up @@ -2126,7 +2126,7 @@ protected function defineRules(): array
$rules[] = [
['siteId'],
SiteIdValidator::class,
'allowDisabled' => $this->propagating ?: null,
'allowDisabled' => true,
'on' => [self::SCENARIO_DEFAULT, self::SCENARIO_LIVE, self::SCENARIO_ESSENTIALS],
];
$rules[] = [['dateCreated', 'dateUpdated'], DateTimeValidator::class, 'on' => [self::SCENARIO_DEFAULT, self::SCENARIO_LIVE]];
Expand Down

0 comments on commit 5412e2b

Please sign in to comment.