X-Git-Url: https://nos-oignons.net/gitweb/gestion-adh.git/blobdiff_plain/febcaa4d9fbe691c63473c2129788c0dbbe5cce0..0b86faada8b828ca94b735ec4bf88b7e024f16a3:/bin/list-emails?ds=inline diff --git a/bin/list-emails b/bin/list-emails index 4c8a286..5315d86 100755 --- a/bin/list-emails +++ b/bin/list-emails @@ -5,13 +5,6 @@ require 'rubygems' require 'bundler' Bundler.setup -require 'nos_oignons/subscriptions' +require 'nos_oignons' -subscriptions = read_subscriptions -now = Time.now -last_year = Time.new(now.year - 1, now.month, now.day).to_date -subscriptions.each_pair do |subscription_id, data| - if data['membership_fee_paid_on'] && last_year < data['membership_fee_paid_on'] - puts data['email'] - end -end +NosOignons.list_emails!