Skip to content

Commit

Permalink
Even more compact.
Browse files Browse the repository at this point in the history
  • Loading branch information
Gabe Berke-Williams committed Feb 7, 2012
1 parent cec58dd commit eb731fe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app.rb
Expand Up @@ -10,8 +10,8 @@
number_of_pictures_to_return = [corgis.count, count.to_i].min

random_corgis = corgis.shuffle![1..number_of_pictures_to_return]
corgi_urls = random_corgis.map(&:url)
corgi_urls.to_json

random_corgis.map(&:url).to_json
end

get '/random' do
Expand Down

0 comments on commit eb731fe

Please sign in to comment.