Thousands of duplicated members in relation 6040654


I just noticed this monster multipolygon with > 12000 members,

Nearly all members are duplicated and some members are closed ways
which are single islands. JOSM seems to hang when I try to edit the relation,
so I think this should work:
save as *.osm file, open with an editor, mark all lines with
“member type”, use editor funtion to " sort and remove duplicates",
add action=‘modify’ to the relation and safe the file.
Load the modified file into JOSM and upload it.

Is there a better way to do this?


For the record, this relation has been deleted in changeset 41,898,267