Browse Source

A slightly better set of names

Stephen Starkey 5 months ago
parent
commit
cab868d819
1 changed files with 4 additions and 4 deletions
  1. 4
    4
      src/ensure_mounted/core.clj

+ 4
- 4
src/ensure_mounted/core.clj View File

@@ -17,16 +17,16 @@
17 17
 
18 18
 (defn lines [filename] (with-open [r (reader filename)] (doall (line-seq r))))
19 19
 
20
-(defn assess-line [{:keys [active?] :as result} line]
20
+(defn qualify-line [{:keys [active?] :as result} line]
21 21
   (cond
22 22
     (start-ensure? line) (assoc result :active? true)
23 23
     (end-ensure? line) (assoc result :active? false)
24 24
     active? (update result :lines conj line)
25 25
     :else result))
26 26
 
27
-(def->> desired-block (reduce assess-line {:active? false, :lines []}) :lines)
27
+(def->> desired-block (reduce qualify-line {:active? false, :lines []}) :lines)
28 28
 
29
-(defn assess-mount-result [results {:keys [exit err]}]
29
+(defn add-mount-result [results {:keys [exit err]}]
30 30
   (if (= 0 exit)
31 31
     results
32 32
     (-> results (assoc :failed? true) (update :errs conj err))))
@@ -37,7 +37,7 @@
37 37
         necessary (set/difference desired existing)
38 38
         results (doall (map mount! necessary))]
39 39
     (if (seq desired)
40
-      (reduce assess-mount-result {:failed? false, :errs []} results)
40
+      (reduce add-mount-result {:failed? false, :errs []} results)
41 41
       {:failed? true
42 42
        :errs ["Unable to find any mount points. Is your fstab annotated?"]})))
43 43