Skip to content

Commit 126f31f

Browse files
authored
Update README.md
1 parent 6c62120 commit 126f31f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,18 +45,18 @@ public class MyDbContextFactory : IDbContextFactory<MyDbContext>
4545
```
4646
3. In your model you need to declare References using the type LazyReference<T> as in the example below:
4747
```c#
48-
public class Course
48+
public class Department
4949
{
50-
private LazyReference<Department> _departmentLazy = new LazyReference<Department>();
51-
public Department Department
50+
private LazyReference<Instructor> _administratorLazy = new LazyReference<Instructor>();
51+
public Instructor Administrator
5252
{
5353
get
5454
{
55-
return _departmentLazy.GetValue(this, nameof(Department));
55+
return _administratorLazy.GetValue(this, nameof(Administrator));
5656
}
5757
set
5858
{
59-
_departmentLazy.SetValue(value);
59+
_administratorLazy.SetValue(value);
6060
}
6161
}
6262
}

0 commit comments

Comments
 (0)