Skip to content
Snippets Groups Projects
Commit e91fa832 authored by Cam Saül's avatar Cam Saül
Browse files

New script to check for reflection warnings :unamused:

parent 3b61f62d
No related branches found
No related tags found
No related merge requests found
...@@ -3,9 +3,9 @@ ...@@ -3,9 +3,9 @@
warnings=`lein check 2>&1 | grep Reflection | grep metabase` warnings=`lein check 2>&1 | grep Reflection | grep metabase`
if [ ! -z "$warnings" ]; then if [ ! -z "$warnings" ]; then
echo -e "\e[4;31mYour code has cased introduced some reflection warnings.\e[0m 😞" echo -e "\e[1;31mYour code has cased introduced some reflection warnings.\e[0m 😞"
echo "$warnings"; echo "$warnings";
exit -1; exit -1;
fi fi
echo "\e[1;32mNo reflection warnings! Success.\e[0m" echo -e "\e[1;32mNo reflection warnings! Success.\e[0m"
...@@ -86,7 +86,7 @@ ...@@ -86,7 +86,7 @@
(-> field-def (-> field-def
(update :count safe-inc) (update :count safe-inc)
(update :len #(if (string? field-value) (update :len #(if (string? field-value)
(+ (or % 0) (.length field-value)) (+ (or % 0) (count field-value))
%)) %))
(update :types (fn [types] (update :types (fn [types]
(update types (type field-value) safe-inc))) (update types (type field-value) safe-inc)))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment