Commit 5138dea
committed
Swallow
When the database is empty, the call to `ITopicRepository.Load("Configuration")` is _expected_ to return a `TopicNotFoundException`. As part of the empty repository support, however, we don't want this to prevent rendering of the application when `GetContentTypeDescriptors()` is called. As such, we're swalling this exception.
Unfortunately, this is introducing a `CA1031`, which happens when capturing a general exception. The only problem is that this isn't a general exception. This used to be a bug in Roslyn Code Analyzers, but it was fixed in 2.9.7. It may have been reintroduced in 3.0.0? Regardless, I've reported the issue to the Roslyn team, but in the meanwhile we'll need to suppress the issue.TopicNotFoundException in GetContentTypeDescriptors()
1 parent 2300e69 commit 5138dea
2 files changed
Lines changed: 13 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
7 | | - | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
67 | 67 | | |
68 | 68 | | |
69 | 69 | | |
70 | | - | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
71 | 78 | | |
72 | 79 | | |
73 | 80 | | |
| |||
0 commit comments