Description:
Refactor.
Commit status:
[Not Reviewed]
References:
Comments:
0 Commit comments 0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
Add another comment

r31:ff42990fe527 -

@@ -114,19 +114,19
114 :level :warning ;going with warning because a project might not have a license before release.
114 :level :warning ;going with warning because a project might not have a license before release.
115 :follow-up "Add a license to LICENSE. Consider using https://choosealicense.com/ for guidance." }])
115 :follow-up "Add a license to LICENSE. Consider using https://choosealicense.com/ for guidance." }])
116
116
117 (def false-colors {:suggestion :blue
118 :warning :yellow
119 :error :red})
120
121 (def level-prefixes {:suggestion "Suggested "
122 :warning "Recommended "
123 :error "Required "})
124
117 (defn perform-check [check project]
125 (defn perform-check [check project]
118 (let [{check-name :name :keys [function follow-up level]} check
126 (let [{check-name :name :keys [function follow-up level]} check
119 result (function project)
127 result (function project)
120 false-color (case level
128 false-color (level false-colors :red)
121 :suggestion :blue
129 prefix (level level-prefixes "Follow-up")]
122 :warning :yellow
123 :error :red
124 :red)
125 prefix (case level
126 :suggestion "Suggested "
127 :warning "Recommended "
128 :error "Required "
129 "Follow-up")]
130 {:name check-name
130 {:name check-name
131 :result result
131 :result result
132 :output (if result
132 :output (if result
You need to be logged in to leave comments. Login now