haplokuon / netDxf

.net dxf Reader-Writer
MIT License
1.01k stars 411 forks source link

Invalid check in the Insert constructor #241

Closed FilatovAV closed 3 years ago

FilatovAV commented 3 years ago

Invalid check in the Insert constructor

now

            if (scale <= 0)
            {
                throw new ArgumentOutOfRangeException(nameof(scale), scale, "The Insert scale must be greater than zero.");
            }

must be

            if (scale == 0)
            {
                throw new ArgumentOutOfRangeException(nameof(scale), scale, "The Insert scale should not be zero.");
            }
haplokuon commented 3 years ago

Negative scale values should be allowed in the Insert constructor as it is in the Scale property.