Reworked modal call and added a validation method for compatibility