debugging...
[RRRRHHHH_Code] / ruralHouses / src / gui / listOfAdditionRequestsGUI.java
index 8a24d45..0fbf336 100644 (file)
@@ -90,10 +90,10 @@ public class listOfAdditionRequestsGUI extends JFrame {
                                        RuralHouse rh = houses.get(table.getSelectedRow());
                                        //TODO when the house is not added show a warning to the user. Method below returns a boolean stating that.
                                        hm.registerNewHouse(rh);
-                                       houses.remove(rh);
                                        am.removeHouseAdditionRequests(rh);
                                        Administrator.saveInstance();
                                        ((DefaultTableModel)table.getModel()).removeRow(houses.indexOf(rh));
+                                       houses.remove(rh);
                                }
                        }
                });