Refactor bse validtaion.