aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* optimize string literals in erb templatesAaron Patterson2013-12-031-2/+2
|
* Remove earlier return in favor of conditionalCarlos Antonio da Silva2013-12-031-6/+9
|
* Change delimiter check order: first check if it is presentCarlos Antonio da Silva2013-12-031-3/+3
| | | | | | | This reads a lot better, and we won't need to try start_with? for blank delimiters. Also rename method name to read better.
* Make both conversion methods work similarlyCarlos Antonio da Silva2013-12-031-1/+2
| | | | | The conversion without area code already changed the passed number in place, so change the other method to do the same.
* Remove useless empty stringCarlos Antonio da Silva2013-12-031-2/+1
|
* No need for #tapCarlos Antonio da Silva2013-12-031-4/+3
|
* Avoid a hash creation since defaults is a new hash alreadyCarlos Antonio da Silva2013-12-031-1/+1
|
* Stop using local variables everywhere, make use of the readerCarlos Antonio da Silva2013-12-036-20/+20
|
* Refactor to avoid earlier returnsCarlos Antonio da Silva2013-12-031-5/+9
|
* Rename variable that holds whether or not the class should validate a float ↵Carlos Antonio da Silva2013-12-035-9/+9
| | | | number
* Change deep_munge call to avoid deprecation warningCarlos Antonio da Silva2013-12-031-2/+2
|
* Improve AR changelog, add entry for migration error improvements #12462 [ci ↵Carlos Antonio da Silva2013-12-031-2/+12
| | | | skip]
* Merge pull request #12462 from jjb/improve_ar_exception_message_formattingCarlos Antonio da Silva2013-12-031-8/+15
|\ | | | | Improve formatting of ActiveRecord migration exception messages
| * ActiveRecord migration exception message formattingJohn Joseph Bachir2013-12-031-8/+15
| |
* | Merge pull request #13149 from laurocaetano/fix_offset_lastCarlos Antonio da Silva2013-12-033-1/+16
|\ \ | | | | | | Fix offset with last.
| * | Fix offset with last.Lauro Caetano2013-12-033-1/+16
| |/ | | | | | | Closes #7441
* | Remove the escaping skipRafael Mendonça França2013-12-031-1/+1
| | | | | | | | | | We are generating safe strings in the paragraph, so we can escape the tags
* | Merge branch 'master-sec'Aaron Patterson2013-12-038-18/+38
|\ \ | |/ |/| | | | | | | | | | | | | * master-sec: Deep Munge the parameters for GET and POST Stop using i18n's built in HTML error handling. Ensure simple_format escapes its html attributes Escape the unit value provided to number_to_currency Only use valid mime type symbols as cache keys
| * Deep Munge the parameters for GET and POSTMichael Koziarski2013-12-022-2/+17
| | | | | | | | | | | | | | | | The previous implementation of this functionality could be accidentally subverted by instantiating a raw Rack::Request before the first Rails::Request was constructed. Fixes CVE-2013-6417
| * Stop using i18n's built in HTML error handling.Michael Koziarski2013-12-022-14/+10
| | | | | | | | | | | | | | | | | | i18n doesn't depend on active support which means it can't use our html_safe code to do its escaping when generating the spans. Rather than try to sanitize the output from i18n, just revert to our old behaviour of rescuing the error and constructing the tag ourselves. Fixes: CVE-2013-4491
| * Ensure simple_format escapes its html attributesMichael Koziarski2013-12-021-1/+1
| | | | | | | | | | | | | | | | | | | | The previous behavior equated the sanitize option for simple_format with the escape option of content_tag, however these are two distinct concepts. This fixes CVE-2013-6416 Conflicts: actionview/lib/action_view/helpers/text_helper.rb
| * Escape the unit value provided to number_to_currencyMichael Koziarski2013-12-022-1/+3
| | | | | | | | | | | | Previously the unit values were trusted leading to potential XSS vulnerabilities. Fixes: CVE-2013-6415
| * Only use valid mime type symbols as cache keysAaron Patterson2013-12-021-0/+7
| | | | | | | | CVE-2013-6414
* | `connection.type_to_sql` returns a `String` for unmapped types.Yves Senn2013-12-033-1/+16
| | | | | | | | | | | | | | | | | | | | Closes #13146. This fixes an error when using: ``` change_colum :table, :column, :bigint, array: true ```
* | Changelog improvements [ci skip]Carlos Antonio da Silva2013-12-032-6/+6
| |
* | Merge pull request #9685 from dimko/patch-2Carlos Antonio da Silva2013-12-034-21/+42
|\ \ | | | | | | Added Date#all_week/month/quarter/year for generating date ranges
| * | Added Date#all_week/month/quarter/year for generating date rangesDimko2013-12-034-21/+42
|/ /
* | Merge pull request #12822 from cbartlett/masterCarlos Antonio da Silva2013-12-033-4/+43
|\ \ | | | | | | Add support for localized date references
| * | Add support for localized date referencesColin Bartlett2013-12-033-0/+39
| | | | | | | | | | | | | | | | | | | | | Ruby's Date class automatically gives us #yesterday, #today, and #tomorrow. And ActiveSupport has a handy Time.zone.today for getting a localized version. But there was no localized version of #yesterday or #tomorrow. Until now.
| * | Use travel_to convention in existing testColin Bartlett2013-12-031-4/+4
| | |
* | | Merge pull request #13145 from acapilleri/fix_email_exampleCarlos Antonio da Silva2013-12-031-1/+1
|\ \ \ | |/ / |/| | fix email regex example code [ci skip]
| * | fix email regex example code [ci skip]Angelo capilleri2013-12-031-1/+1
| | | | | | | | | | | | different from the regex in EmailValidator
* | | Merge pull request #13143 from ↵Rafael Mendonça França2013-12-031-2/+2
|\ \ \ | | | | | | | | | | | | | | | | joker1007/fix_active_record_callbacks_document_bug Fix ActiveRecord::Callbacks sample code [ci skip]
| * | | Fix ActiveRecord::Callbacks sample code [ci skip]joker10072013-12-031-2/+2
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | Callback caller class uses `after_initialize`, but Callback callee defines `after_find`. Current sample code causes following error. NoMethodError: undefined method `after_initialize' for #<EncryptionWrapper:0x007fe4931fa5c0>
* | | Fix bad usage of #select with hashCarlos Antonio da Silva2013-12-031-1/+1
| | |
* | | Merge pull request #11643 from vipulnsward/query_cache_clearCarlos Antonio da Silva2013-12-033-1/+15
|\ \ \ | | | | | | | | Fix QueryCache to work with nested blocks
| * | | Currently, we clear query_cache in cache block finish, even if we may ↵Vipul A M2013-12-033-1/+15
|/ / / | | | | | | | | | | | | | | | already have cache true. This commit takes into account the last cache_enabled value, before clearing query_cache.
* | | Merge pull request #13022 from pwnall/fixture_contextYves Senn2013-12-036-1/+116
|\ \ \ | | | | | | | | Introduce a context for rendering fixtures ERB.
| * | | Introduce a context for rendering fixtures ERB.Victor Costan2013-12-036-1/+116
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixture files are passed through an ERB renderer before being read as YAML. The rendering is currently done in the context of the main object, so method definitons leak into other fixtures, and there is no clean place to define fixture helpers. After this commit, the ERB renderer will use a new subclass of ActiveRecord::FixtureSet.context_class each time a fixture is rendered.
* | | Convert Mime::NullType in a singletonGuillermo Iguaran2013-12-031-1/+4
| | |
* | | Cleanups in comment about conditionalGuillermo Iguaran2013-12-031-1/+2
| | |
* | | Merge branch 'format_localized_template' of https://github.com/acapilleri/railsGuillermo Iguaran2013-12-034-1/+22
|\ \ \ | | | | | | | | | | | | | | | | Conflicts: actionpack/CHANGELOG.md
| * | | Fix header Content-Type: #<Mime::NullType:...> in localized templateAngelo capilleri2013-12-034-1/+22
| |/ / | | | | | | | | | | | | | | | | | | | | | This PR fixes #13064 regression bug introduced by the #8085 Now in _process_format when the format is a Mime::NullType nothing is written in self.content_type. In this way the method Response#assign_default_content_type_and_charset can write the the default mime_type.
* | | Tidy up previous commit, fix message assertion and improve testsCarlos Antonio da Silva2013-12-032-2/+9
| | |
* | | Modify the Hash#assert_valid_keys error message so that it shows the valid ↵Nerian2013-12-033-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | keys. Also, show the wrong value as it was entered. { :failore => "stuff", :funny => "business" }.assert_valid_keys([ :failure, :funny ]) => ArgumentError: Unknown key: failore { 'failore' => "stuff", :funny => "business" }.assert_valid_keys([ :failure, :funny ]) => ArgumentError: Unknown key: failore { 'failore' => "stuff", :funny => "business" }.assert_valid_keys([ :failure, :funny ]) => ArgumentError: Unknown key: "failore". Valid keys are: :failure, :funny { :failore => "stuff", :funny => "business" }.assert_valid_keys([ :failure, :funny ]) => ArgumentError: Unknown key: :failore. Valid keys are: :failure, :funny Conflicts: activerecord/CHANGELOG.md Closes #11624.
* | | Merge pull request #13060 from chancancode/change_log_for_json_refactorCarlos Antonio da Silva2013-12-023-0/+59
|\ \ \ | | | | | | | | CHANGELOG for JSON refactor + added back the `encode_big_decimal_as_string` option with warning
| * | | Added back the `encode_big_decimal_as_string` option with warningGodfrey Chan2013-12-023-0/+59
| | | | | | | | | | | | | | | | | | | | Also added the missing CHANGELOG entry for #12183 @ 80e7552073 and 4d02296cfb.
* | | | Avoid generating more strings while iterating to create methodsCarlos Antonio da Silva2013-12-021-1/+1
| |_|/ |/| | | | | | | | | | | Use the already existing strings instead of creating a new one each time just to test if it responds to the methods.
* | | Merge remote-tracking branch 'origin/master'Rafael Mendonça França2013-12-0218-21/+41
|\ \ \
| * \ \ Merge pull request #12123 from aredondo/masterCarlos Antonio da Silva2013-12-021-0/+8
| |\ \ \ | | | | | | | | | | | | | | | | | | | | Add regression test for IpSpoofAttackError issue Closes #10780