code: public static void addEmailPropsToFlow(final Flow flow, final Props prop) {
      final List<String> successEmailList =
          prop.getStringList(CommonJobProperties.SUCCESS_EMAILS,
              Collections.EMPTY_LIST);
      final Set<String> successEmail = new HashSet<>();
      for (final String email : successEmailList) {
        successEmail.add(email.toLowerCase());
      }
  
      final List<String> failureEmailList =
          prop.getStringList(CommonJobProperties.FAILURE_EMAILS,
              Collections.EMPTY_LIST);
      final Set<String> failureEmail = new HashSet<>();
      for (final String email : failureEmailList) {
        failureEmail.add(email.toLowerCase());
      }
  
      final List<String> notifyEmailList =
          prop.getStringList(CommonJobProperties.NOTIFY_EMAILS,
              Collections.EMPTY_LIST);
      for (String email : notifyEmailList) {
        email = email.toLowerCase();
        successEmail.add(email);
        failureEmail.add(email);
      }
  
      flow.addFailureEmails(failureEmail);
      flow.addSuccessEmails(successEmail);
    }
docs: Adds email properties to a flow.
  
  @param flow the flow
  @param prop the prop