def get_transitions(state_list, xml_transition_list):
    """Get transitions if state(s) from state_list are source/destination"""
    new_transition_list = set()
    for new_state in state_list:
        for transition in xml_transition_list:
            if new_state.id == transition.source:
                new_transition_list.add(transition)
            if new_state.id == transition.destination:
                new_transition_list.add(transition)

    return new_transition_list