Skip to content

Commit a2a8701

Browse files
committed
PropertyValidator: init instead of set for bool properties
1 parent 7b398d0 commit a2a8701

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Orm/Xtensive.Orm/Orm/Validation/PropertyValidator.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ public bool IsImmediate
3939
public bool ValidateOnlyIfModified
4040
{
4141
get => validateOnlyIfModified;
42-
set {
42+
init {
4343
if (Domain != null) {
4444
throw Exceptions.AlreadyInitialized(null);
4545
}
@@ -53,7 +53,7 @@ public bool ValidateOnlyIfModified
5353
public bool SkipOnTransactionCommit
5454
{
5555
get => skipOnTransactionCommiting;
56-
set {
56+
init {
5757
if (Domain != null) {
5858
throw Exceptions.AlreadyInitialized(null);
5959
}

0 commit comments

Comments
 (0)