               (spit 
                (str
                 "resources/video_ids/"
-                (config/all :daemon-name)
+                ((config/get-by-name daemon-name) :daemon-name)
                 "/"
                 "urls"
                 index

      tmp-data)))


(defn gen-captions-to-delete []
  (let [file (->>
              (config/all :srt-source-folders)
              get-all-subtitle-file-objs

     (set)
     (clojure.set/difference (set file))
     (reduce (fn [s f] (str s " ./" f)) "")
     (#(spit (str (first ((config/get-by-name daemon-name) :srt-source-folders)) "/rm-script.sh") (str "rm " %)))))) 
