lib/postgis_functions.rb in nofxx-postgis_adapter-0.5.7 vs lib/postgis_functions.rb in nofxx-postgis_adapter-0.7.0

- old
+ new

@@ -20,12 +20,12 @@ EARTH_SPHEROID = "'SPHEROID[\"GRS-80\",6378137,298.257222101]'" # SRID => 4326 def postgis_calculate(operation, subjects, options = {}) subjects = [subjects] unless subjects.respond_to?(:map) return execute_geometrical_calculation(operation, subjects, options) - rescue Exception => e - raise StandardError, "#{e}" + #rescue Exception => e + #raise StandardError, "#{e}" end def geo_columns @geo_columns ||= postgis_geoms[:columns] end @@ -42,10 +42,10 @@ def construct_geometric_sql(type,geoms,options) not_db, on_db = geoms.partition { |g| g.is_a? Geometry } tables = on_db.map do |t| { :name => t.class.table_name, - :column => t.geo_columns.first, + :column => t.postgis_geoms.keys[0], :uid => unique_identifier, :id => t[:id] } end # Implement a better way for options?