validates_presence_of :user_id, :name, :timestamp
validates_presence_of :description, :on => :create
- validates_format_of :tagstring, :with => /^[^\/;.,?]*$/
# validates_numericality_of :latitude, :longitude
validates_inclusion_of :public, :inserted, :in => [ true, false]
self.icon_picture = gpx.get_icon(min_lat, min_lon, max_lat, max_lon)
self.size = gpx.actual_points
self.inserted = true
- self.save
+ self.save!
end
logger.info "done trace #{id}"