Skip to content

Commit

Permalink
Graceful degradation for MetaWhere::Column via #to_s
Browse files Browse the repository at this point in the history
  • Loading branch information
Ernie Miller committed Aug 20, 2010
1 parent 6ab206c commit f4fb0fa
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions lib/meta_where/column.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,10 @@ def to_sym
self
end

# Let's degrade hracefully if someone expects us to be a symbol or something
def to_s
@column
end

end
end
2 changes: 1 addition & 1 deletion vendor/rails
Submodule rails updated 60 files
+2 −1 Gemfile
+28 −0 Rakefile
+2 −0 actionmailer/lib/action_mailer/deprecated_api.rb
+11 −2 actionpack/lib/action_dispatch/middleware/best_standards_support.rb
+1 −0 actionpack/lib/action_dispatch/routing/deprecated_mapper.rb
+4 −1 actionpack/lib/action_dispatch/routing/mapper.rb
+1 −0 actionpack/lib/action_dispatch/testing/integration.rb
+1 −1 actionpack/lib/action_view/helpers/form_tag_helper.rb
+1 −0 actionpack/lib/action_view/helpers/sanitize_helper.rb
+1 −0 actionpack/test/controller/resources_test.rb
+25 −30 actionpack/test/dispatch/routing_test.rb
+1 −1 actionpack/test/template/form_helper_test.rb
+1 −1 actionpack/test/template/form_tag_helper_test.rb
+1 −1 activemodel/lib/active_model/attribute_methods.rb
+9 −9 activemodel/lib/active_model/serializers/json.rb
+7 −7 activerecord/Rakefile
+5 −8 activerecord/lib/active_record/associations.rb
+5 −4 activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb
+639 −0 activerecord/lib/active_record/connection_adapters/mysql2_adapter.rb
+3 −1 activerecord/lib/active_record/relation.rb
+1 −0 activerecord/lib/active_record/relation/calculations.rb
+1 −1 activerecord/lib/active_record/schema.rb
+9 −9 activerecord/lib/active_record/schema_dumper.rb
+1 −1 activerecord/test/cases/adapters/mysql/active_schema_test.rb
+125 −0 activerecord/test/cases/adapters/mysql2/active_schema_test.rb
+42 −0 activerecord/test/cases/adapters/mysql2/connection_test.rb
+176 −0 activerecord/test/cases/adapters/mysql2/reserved_word_test.rb
+1 −1 activerecord/test/cases/associations/belongs_to_associations_test.rb
+7 −2 activerecord/test/cases/associations/has_and_belongs_to_many_associations_test.rb
+15 −13 activerecord/test/cases/attribute_methods_test.rb
+1 −1 activerecord/test/cases/base_test.rb
+1 −1 activerecord/test/cases/calculations_test.rb
+34 −0 activerecord/test/cases/column_definition_test.rb
+1 −1 activerecord/test/cases/defaults_test.rb
+7 −0 activerecord/test/cases/method_scoping_test.rb
+6 −6 activerecord/test/cases/migration_test.rb
+1 −1 activerecord/test/cases/query_cache_test.rb
+15 −3 activerecord/test/cases/relations_test.rb
+2 −2 activerecord/test/cases/schema_dumper_test.rb
+1 −0 activerecord/test/cases/timestamp_test.rb
+41 −0 activerecord/test/cases/transaction_callbacks_test.rb
+25 −0 activerecord/test/connections/native_mysql2/connection.rb
+24 −0 activerecord/test/schema/mysql2_specific_schema.rb
+5 −1 activeresource/lib/active_resource/http_mock.rb
+10 −5 activesupport/lib/active_support/callbacks.rb
+8 −8 activesupport/lib/active_support/concern.rb
+22 −0 activesupport/lib/active_support/core_ext/class/inheritable_attributes.rb
+10 −1 activesupport/lib/active_support/ordered_hash.rb
+16 −0 activesupport/lib/active_support/ordered_options.rb
+19 −12 activesupport/test/core_ext/date_time_ext_test.rb
+25 −10 railties/guides/source/action_controller_overview.textile
+1 −1 railties/guides/source/active_record_querying.textile
+314 −141 railties/guides/source/active_support_core_extensions.textile
+1 −1 railties/guides/source/form_helpers.textile
+4 −0 railties/guides/source/index.html.erb
+1 −0 railties/guides/source/layout.html.erb
+6 −0 railties/guides/source/routing.textile
+1 −1 railties/lib/rails/application.rb
+4 −0 railties/lib/rails/generators/rails/app/templates/config/environments/development.rb.tt
+65 −31 railties/test/application/routing_test.rb

0 comments on commit f4fb0fa

Please sign in to comment.