Created
October 5, 2011 02:03
-
-
Save padi/1263438 to your computer and use it in GitHub Desktop.
Rake Task for Updating Conditions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
desc 'Update traffic condition' | |
task :update_condition => :environment do | |
Report.all.each do |report| | |
report.update_attribute(:conditions, Tweet.new(report).conditions) unless report.user | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment