summaryrefslogtreecommitdiff
path: root/bin/community
diff options
context:
space:
mode:
Diffstat (limited to 'bin/community')
-rwxr-xr-xbin/community6
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/community b/bin/community
index 84cf0bd..111846e 100755
--- a/bin/community
+++ b/bin/community
@@ -69,7 +69,8 @@ class Census
def each
CSV.foreach(@path, headers: true) do |row|
- yield Community.new(row)
+ community = Community.new(row)
+ yield community if community[:class].include?("Residential")
end
end
@@ -77,8 +78,7 @@ class Census
erb = ERB.new(IO.read("templates/communities.md.erb"), trim_mode: "-")
IO.write("#{dir}/README.md", erb.result(binding))
- find_all { |x| x[:class].include?("Residential") }
- .each { |x| x.create_content_in(dir) }
+ each { |x| x.create_content_in(dir) }
end
end