refactoring hook for add meta data in case and person