aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/base.rb
Commit message (Collapse)AuthorAgeFilesLines
...
* | Perf: don't mess around with thread local vars unless we actually need toJon Leighton2011-08-131-18/+23
| |
* | Fix default scope thread safety. Thanks @thedarkone for reporting.Jon Leighton2011-08-131-15/+26
| |
* | Fully marshal AR::Base objects. Fixes #2431.Jon Leighton2011-08-081-21/+0
| |
* | Make it the responsibility of the connection to hold onto an ARel visitor ↵Jon Leighton2011-08-081-2/+1
| | | | | | | | for generating SQL. This improves the code architecture generally, and solves some problems with marshalling. Adapter authors please take note: you now need to define an Adapter.visitor_for method, but it degrades gracefully with a deprecation warning for now.
* | Revert "Explicitly included hashes in sentence regarding SQL-injection-safe ↵Xavier Noria2011-08-041-3/+3
| | | | | | | | | | | | | | | | forms" Reason: The hash form is secure, and preferred over the array form if possible. This reverts commit 6dc749596c328c44c80f898d5fa860fff6cab783.
* | Explicitly included hashes in sentence regarding SQL-injection-safe formsPete Campbell2011-08-041-3/+3
|/
* fix after_initialize edge case (close #2074 and close #2175)Les Fletcher2011-07-241-2/+1
| | | | fix behavior when after_initialize is defined and a block is passed to Base.create
* Merge pull request #2185 from castlerock/lazy_load_abstract_adapterAaron Patterson2011-07-231-2/+0
|\ | | | | lazy load ConnectionAdapters remove require.
| * lazy load ConnectionAdapters remove require.Vishnu Atrai2011-07-221-2/+0
| |
* | Merge pull request #2086 from amatsuda/date_multiparameter_nilXavier Noria2011-07-231-3/+6
|\ \ | | | | | | convert multiple Date parameters into a nil if any of its bits were blank
| * | convert multiple Date parameters into a nil if any of its bits were blankAkira Matsuda2011-07-151-3/+6
| | |
* | | Merge branch 'master' of git://github.com/lifo/docrailsXavier Noria2011-07-231-1/+1
|\ \ \ | |_|/ |/| |
| * | use simpler words in docsVijay Dev2011-07-101-1/+1
| | |
* | | Refactor the code a bit to reduce the duplicationPrem Sichanugrist2011-07-171-17/+8
| | |
* | | Raise an ArgumentError if user passing less number of argument in the ↵Prem Sichanugrist2011-07-171-0/+10
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | dynamic finder The previous behavior was unintentional, and some people was relying on it. Now the dynamic finder will always expecting the number of arguments to be equal or greater (so you can still pass the options to it.) So if you were doing this and expecting the second argument to be nil: User.find_by_username_and_group("sikachu") You'll now get `ArgumentError: wrong number of arguments (1 for 2).` You'll then have to do this: User.find_by_username_and_group("sikachu", nil)
* | Fix and unit test for https://github.com/rails/rails/issues/2059Evan Light2011-07-141-1/+2
|/ | | | | | | | | | | | Cache key was incorrectly using timezone-dependent record#updated_at when it should be using a timezone-independent value to generate the cache key Minor refactoring to cache_key timezone test Closes #2059 Adds a test to validate the format of the cache_key for nil and present updated_at values Correctly handles updated_at == nil
* Merge pull request #1273 from jeremyf/feature-association-proxy-sendSantiago Pastorino2011-07-061-1/+1
|\ | | | | Addresses an inconsistency in the ActiveRecord::Base.method_missing handl
| * Addresses an inconsistency in the ActiveRecord::Base.method_missing handling ↵Jeremy Friesen2011-05-241-1/+1
| | | | | | | | of dynamic finder methods and the passing of the &block parameter for :find_by_attributes.
* | Use an instance variable to store the current masss assignment optionsAndrew White2011-07-041-9/+14
| |
* | call super rather than delegating to the other objects equal? methodAaron Patterson2011-06-301-1/+1
| |
* | just alias eql? to == for frewer method callsAaron Patterson2011-06-301-5/+1
| |
* | Define to_ary on ActiveRecord::Base to return nil. Improve performance of ↵Jon Leighton2011-06-301-0/+12
| | | | | | | | Array#flatten under 1.9, see comment for details.
* | Merge pull request #1860 from dmathieu/comparisonAaron Patterson2011-06-281-0/+9
|\ \ | | | | | | Allow comparison on model objects - Closes #1858
| * | comparing different classes returns nilDamien Mathieu2011-06-261-1/+5
| | |
| * | allow comparison on model objects - Closes #1858Damien Mathieu2011-06-261-0/+5
| | |
* | | remove useless assignmentAaron Patterson2011-06-281-2/+1
| | |
* | | reduce object allocation during AR instantiationAaron Patterson2011-06-281-0/+2
| | |
* | | remove the check for needs_type_condition? because ensure_proper_type will ↵Aaron Patterson2011-06-271-2/+3
| | | | | | | | | | | | pick up the type column
* | | stop using && for the short circuit side effectAaron Patterson2011-06-271-1/+1
| | |
* | | let strings be converted to symbols inside the interpreterAaron Patterson2011-06-271-2/+2
| | |
* | | avoice paying hash cost if there are no serialized attributesAaron Patterson2011-06-271-3/+4
| | |
* | | cache column defaults for AR object instantiationAaron Patterson2011-06-271-0/+6
| | |
* | | AR object instantiation is ~30% faster in the simple caseAaron Patterson2011-06-271-1/+1
| | |
* | | initialize instance variablesAaron Patterson2011-06-271-0/+2
|/ /
* | Perf fix - Use an instance variable instead of a class_attribute. Thanks ↵Jon Leighton2011-06-161-8/+4
| | | | | | | | @josevalim and @jhawthorn for the prompting.
* | Pass mass-assignment options to nested models - closes #1673.Andrew White2011-06-131-3/+6
| |
* | don't reinitialize the arel_table unless the table_name changesDamien Mathieu2011-06-091-1/+2
| |
* | No need to create a new Arel::Table, as the arel_table method already ↵Rodrigo Navarro2011-06-081-1/+0
| | | | | | | | creates a new one
* | remove warning: assigned but unused variableSantiago Pastorino2011-06-081-1/+1
| |
* | Raise NameError instead of ArgumentError in ActiveSupport::DependenciesAndrew White2011-06-011-1/+0
| | | | | | | | | | | | | | | | ActiveSupport::Dependencies now raises NameError if it finds an existing constant in load_missing_constant. This better reflects the nature of the error which is usually caused by calling constantize on a nested constant. Closes #1423
* | Merge pull request #1285 from joshk/remove_active_record_deprecationsAaron Patterson2011-05-251-15/+2
|\ \ | | | | | | removed deprecated methods, and related tests, from ActiveRecord
| * | removed deprecated methods, and related tests, from ActiveRecordJosh Kalderimis2011-05-251-15/+2
| | |
* | | Fix the AR::Base#inspect method [closes #1294]Franck Verrot2011-05-251-6/+10
|/ /
* / Fix infinite recursion where a lazy default scope references a scope. Fixes ↵Jon Leighton2011-05-251-3/+12
|/ | | | #1264.
* Merge pull request #1180 from Karunakar/documentation_changeXavier Noria2011-05-211-3/+13
|\ | | | | Documentation Error Fixed for ticket #839
| * Documentation Error Fixed for ticket #839Karunakar (Ruby)2011-05-211-3/+13
| |
* | Merge pull request #1162 from guilleiguaran/singularize_individual_table_nameJon Leighton2011-05-211-2/+2
|\ \ | |/ |/| Singularize individual table name
| * Allow pluralize_table_names for individual modelGuillermo Iguaran2011-05-201-2/+2
| |
* | Syntax cleanup: for in => eachGuillermo Iguaran2011-05-191-1/+1
|/
* Add doc to #attribute_namesSebastian Martinez2011-05-151-0/+3
|