set_table_name 'current_nodes'
validates_presence_of :user_id, :timestamp
set_table_name 'current_nodes'
validates_presence_of :user_id, :timestamp
- return false if self.latitude < -90 or self.latitude > 90
- return false if self.longitude < -180 or self.longitude > 180
+ return false if self.lat < -90 or self.lat > 90
+ return false if self.lon < -180 or self.lon > 180
# use the cache if available
elsif self.user.data_public?
user_display_name_cache[self.user_id] = self.user.display_name
# use the cache if available
elsif self.user.data_public?
user_display_name_cache[self.user_id] = self.user.display_name