Commit 2f5b25d
authored
Potential wrong use of assertion (Azure#34574)
We encountered an error while using the SDK where GetAll would always throw. After looking through the code we saw that where an instance of this class is created (TrafficManagerProfileResource), the ctor with the 3rd parameter is never called. I'm guessing that's from the AutoRest codegen.
Maybe adding AssertNotNull rather than AssertNull would fix the problem in the codegen?
How we made it work was to use reflection to get _profileData and set it before calling GetAll()1 parent 04dba6a commit 2f5b25d
File tree
1 file changed
+1
-1
lines changed- sdk/trafficmanager/Azure.ResourceManager.TrafficManager/src/Customization
1 file changed
+1
-1
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
0 commit comments