add condition for check case 2