Commit f0bf633
refactor: improve readability of nested Math.Min in SqlDecimalExtensions
Replace nested Math.Min calls with explicit intermediate variable and clarifying comments. This makes the scale calculation logic more readable by breaking down the three constraints being evaluated:
1. Actual SqlDecimal scale
2. .NET decimal maximum scale (27)
3. Available scale given integer part size1 parent 947a74f commit f0bf633
1 file changed
+8
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
55 | | - | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
56 | 63 | | |
57 | 64 | | |
58 | 65 | | |
| |||
0 commit comments