Consolidating more modals code