<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_deprecation_reason( node: Union[EnumValueDefinitionNode, FieldDefinitionNode] ) -> Optional[str]: """Given a field or enum value node, get deprecation reason as string."""

    from ..execution import get_directive_values

    deprecated = get_directive_values(GraphQLDeprecatedDirective, node)
    return deprecated["reason"] if deprecated else None