Fix bug #51148 - XWPFDocument remove of tables/paragraphs now works correctly, and code is simplified