 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 ;; AdjPanelList/AdjList
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-(defn make-adjudicator-node [adjudicator-info]
+(defn- make-adjudicator-node [adjudicator-info]
   (let [name (:adjudicator/name adjudicator-info)
         id (:adjudicator/id adjudicator-info)
         country (:adjudicator/country adjudicator-info)]

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Utils
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defn get-db [data]
  (let [clean-data (uidb/sanitize data)
        conn (d/create-conn uidb/schema)]
    (d/transact! conn [clean-data])
    (d/db conn)))

(defn export-dance-perfect [db]
  (xml/element
      :DancePerfect
      {:Version "4.1"}

      (map make-adjudicator-node (sort-by :adjudicator/id adjudicator-infos)))
    ))

(defn- export-adj-list [db]
  (let [query-result (d/q '[:find (pull ?id [*])
                            :where
                            [?id :adjudicator/id]] db)]
    (make-adj-list-node query-result)))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; AdjPanelList/PanelList
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
(defn- make-panel-adj-node [query-result seq-number]
  (xml/element
    :PanelAdj
    {:Seq seq-number
     :AdjNumber (:adjudicator/id query-result)}))

(defn- make-panel-node [panel seq-number]
  (let [adjudicator-infos (:adjudicator-panel/adjudicators panel)]
    (xml/element
      :Panel
