fixed bug w.r.t. with custodian and ward