fix image modal next button click