Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

21 lines (18 sloc) 0.368 kB
# Recent handles the 'most-recent' list by logging to a file and keeping a 10-item array.
#
class Recent
def initialize
@@people = []
@@hits = 0
end
def push(person)
@@hits += 1
@@people << person
@@people.uniq!
Twifter::LOG.info person.inspect
@@people.shift if @@people.size > 10
end
def to_a
@@people.reverse
end
end
Jump to Line
Something went wrong with that request. Please try again.