Fixes bug opening form when form is already open