diff --git a/src/Mod/PartDesign/App/FeatureExtrude.cpp b/src/Mod/PartDesign/App/FeatureExtrude.cpp index c778cd7e8b..f3bbe0013d 100644 --- a/src/Mod/PartDesign/App/FeatureExtrude.cpp +++ b/src/Mod/PartDesign/App/FeatureExtrude.cpp @@ -131,13 +131,16 @@ bool FeatureExtrude::hasTaperedAngle() const void FeatureExtrude::onChanged(const App::Property* prop) { - if (prop == &Midplane) { + if (!isRestoring() && prop == &Midplane) { // Deprecation notice: Midplane property is deprecated and has been replaced by SideType in // FreeCAD 1.1 when FeatureExtrude was refactored. + App::DocumentObject* obj = Profile.getValue(); + auto baseName = obj ? obj->getNameInDocument() : ""; Base::Console().warning( - "The 'Midplane' property is deprecated and has been replaced by the 'SideType' " - "property in FeatureExtrude. Please update your script, this property will be " - "removed in a future version.\n" + "The 'Midplane' property being set for the extrusion of %s is deprecated and has " + "been replaced by the 'SideType' property in FeatureExtrude. Please update your script," + " this property will be removed in a future version.\n", + baseName ); if (Midplane.getValue()) { SideType.setValue("Symmetric"); @@ -949,7 +952,6 @@ void FeatureExtrude::onDocumentRestored() SideType.setValue("Two sides"); } else if (Midplane.getValue()) { - // This code is probably now dead, replaced by the onChanged watcher for the Midplane value Midplane.setValue(false); SideType.setValue("Symmetric"); }