X-Git-Url: https://nos-oignons.net/gitweb/gestion-adh.git/blobdiff_plain/65790969dc54dfb6eb8d4ad2e03a01dbd382c170..9cb7fa95bef77a6d1e0888f741c76adc865f1b17:/bin/list-emails?ds=sidebyside diff --git a/bin/list-emails b/bin/list-emails index 935bcd0..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.sort.each 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!