<commit_before>(ns webapp.server.fns
  [:require [clojure.string :as str]]
  [:use [korma.db]]
  [:use [webapp.framework.server.systemfns]]
  [:use [webapp.framework.server.email-service]]
  [:use [webapp.framework.server.encrypt]]
  [:use [korma.core]]
  [:use [clojure.repl]]
  [:use [webapp.framework.server.db-helper]]
  [:use [webapp.framework.server.neo4j-helper]]

  (:use [webapp-config.settings])
  (:use [overtone.at-at])
  (:import [java.util.UUID])
  (:import [java.util TimerTask Timer]))



(def my-pool (mk-pool))








(defn process-ask-for-endorsement [send-endorsement-neo4j-node]
  (if send-endorsement-neo4j-node
    (do
      (send-email
       :message      (str "hi " (:to_full_name  send-endorsement-neo4j-node))
       :subject      (str "hi " (:to_full_name  send-endorsement-neo4j-node))
       :from-email   (:from_email send-endorsement-neo4j-node)
       :from-name    (:from_full_name  send-endorsement-neo4j-node)
       :to-email     (:to_email send-endorsement-neo4j-node)
       :to-name      (:to_full_name  send-endorsement-neo4j-node)
       )
      (neo4j "match n where id(n)={id}
             remove n:AskForEndorsement
             set n:SendEndorsementConfirmFrom
             return n"
             {:id (:neo-id send-endorsement-neo4j-node)} "n")
      )

    ))



<commit_msg>Send sender confirmation email<commit_after>(ns webapp.server.fns
  [:require [clojure.string :as str]]
  [:use [korma.db]]
  [:use [webapp.framework.server.systemfns]]
  [:use [webapp.framework.server.email-service]]
  [:use [webapp.framework.server.encrypt]]
  [:use [korma.core]]
  [:use [clojure.repl]]
  [:use [webapp.framework.server.db-helper]]
  [:use [webapp.framework.server.neo4j-helper]]

  (:use [webapp-config.settings])
  (:use [overtone.at-at])
  (:import [java.util.UUID])
  (:import [java.util TimerTask Timer]))



(def my-pool (mk-pool))








(defn process-ask-for-endorsement [send-endorsement-neo4j-node]
  (if send-endorsement-neo4j-node
    (do
      (send-email
       :message      (str "ConnectToUs.co - " (:from_full_name  send-endorsement-neo4j-node)
                          ", please confirm your endorsement request" )
       :subject      (str "ConnectToUs.co - " (:from_full_name  send-endorsement-neo4j-node)
                          ", please confirm your endorsement request" )
       :from-email   "<EMAIL>"
       :from-name    "ConnectToUs.co"
       :to-email     (:from_email send-endorsement-neo4j-node)
       :to-name      (:from_full_name  send-endorsement-neo4j-node)
       )
      (neo4j "match n where id(n)={id}
             remove n:AskForEndorsement
             set n:AskForEndorsementConfirmSender
             return n"
             {:id (:neo-id send-endorsement-neo4j-node)} "n")
      )

    ))




{'fraction_non_alphanumeric': 0.14890563329745246, 'fraction_numerical': 0.007176175098672408, 'mean_word_length': 2.61139896373057, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7118138', 'n_tokens_mistral': 1068, 'n_tokens_neox': 994, 'n_words': 169}