Index: applications/editors/josm/plugins/reltoolbox/src/relcontext/actions/ReconstructPolygonAction.java
===================================================================
--- applications/editors/josm/plugins/reltoolbox/src/relcontext/actions/ReconstructPolygonAction.java	(revision 36136)
+++ applications/editors/josm/plugins/reltoolbox/src/relcontext/actions/ReconstructPolygonAction.java	(revision 36142)
@@ -64,5 +64,5 @@
         boolean wont = false;
         for (RelationMember m : r.getMembers()) {
-            if (m.isWay() && m.getWay().getReferrers().size() == 1) {
+            if (m.isWay()) {
                 ways.add(m.getWay());
             } else {
@@ -157,8 +157,8 @@
             tags.remove("type");
 
-            // then delete ways that are not relevant (do not take part in other relations of have strange tags)
+            // then delete ways that are not relevant (do not take part in other relations or have strange tags)
             Way candidateWay = null;
             for (Way w : p.ways) {
-                if (w.getReferrers().equals(relations)) {
+                if (w.getReferrers().size() == 1) {
                     // check tags that remain
                     Set<String> keys = new HashSet<>(w.keySet());
@@ -192,5 +192,6 @@
         // only delete the relation if it hasn't been re-used
         if (!relationReused) {
-            commands.add(relationDeleteCommand);
+            // The relation needs to be deleted first, so that undo/redo continue to work properly
+            commands.add(0, relationDeleteCommand);
         }
 
