Modernize code

This commit is contained in:
André Althaus
2024-03-25 11:21:02 +01:00
parent 067c774292
commit a93e94dabb
3 changed files with 91 additions and 112 deletions

View File

@@ -57,11 +57,11 @@ short Scaled::mustExecute() const
const std::list<gp_Trsf>
Scaled::getTransformations(const std::vector<App::DocumentObject*> originals)
{
double factor = Factor.getValue();
double const factor = Factor.getValue();
if (factor < Precision::Confusion()) {
throw Base::ValueError("Scaling factor too small");
}
int occurrences = Occurrences.getValue();
int const occurrences = Occurrences.getValue();
if (occurrences < 2) {
throw Base::ValueError("At least two occurrences required");
}