Skip to content

Commit

Permalink
Use more verbose variable name
Browse files Browse the repository at this point in the history
Change language for loading user data
  • Loading branch information
Kyle Macey committed Aug 20, 2015
1 parent 20112d2 commit a7056c9
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions api/ruby/user-auditing/user_audit.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
client = Octokit::Client.new
users = client.all_users
n = 1
puts "Importing users..."
puts "Aggregating users..."
full_users = users.map { |u|
print "\r#{n}/#{users.count}"
n += 1
Expand All @@ -29,9 +29,12 @@
u.suspended_at.nil? rescue false;
end

two_days = 172800
seconds_in_two_days = 60 * # seconds in an minute
60 * # minutes in an hour
48 # hours in 2 days

recent = suspended.select do |u|
u[:suspended_at] > (Time.now - two_days)
u[:suspended_at] > (Time.now - seconds_in_two_days)
end

puts ""
Expand Down

0 comments on commit a7056c9

Please sign in to comment.