if(!istype(B, /obj/item/weapon/reagent_containers/glass) || !istype(B, /obj/item/weapon/reagent_containers/food))

If you leave it like you did then chemists won't be able to put in beakers anymore