aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #25350 from tricknotes/uri-generic-as-jsonGodfrey Chan2016-06-252-0/+9
|\ | | | | Define `URI::Generic#as_json`
| * Define `URI::Generic#as_json`Ryunosuke Sato2016-06-252-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the URI object is converted as JSON, it is expected that it is a string that means its URI. Expected: ``` >> URI.parse('http://example.com').as_json "http://example.com" ``` Actual: ``` >> URI.parse('http://example.com').as_json {"scheme"=>"http", "user"=>nil, "password"=>nil, "host"=>"example.com", "port"=>80, "path"=>"", "query"=>nil, "opaque"=>nil, "fragment"=>nil, "parser"=> {"regexp"=> {"SCHEME"=>"(?-mix:\\A[A-Za-z][A-Za-z0-9+\\-.]*\\z)", "USERINFO"=>"(?-mix:\\A(?:%\\h\\h|[!$&-.0-;=A-Z_a-z~])*\\z)", "HOST"=> "(?-mix:\\A(?:(?<IP-literal>\\[(?:(?<IPv6address>(?:\\h{1,4}:){6}(?<ls32>\\h{1,4}:\\h{1,4}|(?<IPv4address>(?<dec-octet>[1-9]\\d|1\\d{2}|2[0-4]\\d|25[0-5]|\\d)\\.\\g<dec-octet>\\.\\g<dec-octet>\\.\\g<dec-octet>))|::(?:\\h{1,4}:){5}\\g<ls32>|\\h{,4}::(?:\\h{1,4}:){4}\\g<ls32>|(?:(?:\\h{1,4}:)?\\h{1,4})?::(?:\\h{1,4}:){3}\\g<ls32>|(?:(?:\\h{1,4}:){,2}\\h{1,4})?::(?:\\h{1,4}:){2}\\g<ls32>|(?:(?:\\h{1,4}:){,3}\\h{1,4})?::\\h{1,4}:\\g<ls32>|(?:(?:\\h{1,4}:){,4}\\h{1,4})?::\\g<ls32>|(?:(?:\\h{1,4}:){,5}\\h{1,4})?::\\h{1,4}|(?:(?:\\h{1,4}:){,6}\\h{1,4})?::)|(?<IPvFuture>v\\h+\\.[!$&-.0-;=A-Z_a-z~]+))\\])|\\g<IPv4address>|(?<reg-name>(?:%\\h\\h|[!$&-.0-9;=A-Z_a-z~])*))\\z)", "ABS_PATH"=> "(?-mix:\\A\\/(?:%\\h\\h|[!$&-.0-;=@-Z_a-z~])*(?:\\/(?:%\\h\\h|[!$&-.0-;=@-Z_a-z~])*)*\\z)", "REL_PATH"=> "(?-mix:\\A(?:%\\h\\h|[!$&-.0-;=@-Z_a-z~])+(?:\\/(?:%\\h\\h|[!$&-.0-;=@-Z_a-z~])*)*\\z)", "QUERY"=>"(?-mix:\\A(?:%\\h\\h|[!$&-.0-;=@-Z_a-z~\\/?])*\\z)", "FRAGMENT"=>"(?-mix:\\A(?:%\\h\\h|[!$&-.0-;=@-Z_a-z~\\/?])*\\z)", "OPAQUE"=>"(?-mix:\\A(?:[^\\/].*)?\\z)", "PORT"=> "(?-mix:\\A[\\x09\\x0a\\x0c\\x0d ]*\\d*[\\x09\\x0a\\x0c\\x0d ]*\\z)"}}} ```
* | Extract method to share path expansion logic.Kasper Timm Hansen2016-06-251-11/+16
| | | | | | | | Then just yield the location for the place where we need some extra processing.
* | Simplify `as` passed check.Kasper Timm Hansen2016-06-251-1/+1
| | | | | | | | `if !var.nil?` is the same as just `if var`
* | Merge pull request #25435 from y-yagi/make_as_option_work_with_get_parametersKasper Timm Hansen2016-06-252-2/+18
|\ \ | |/ |/| make `as` option work with get parameters
| * make `as` option work with get parametersyuuji.yaginuma2016-06-252-2/+18
| | | | | | | | | | | | | | | | Currently, if path is a relative path, add format without the discrimination of the query. Therefore, if there is a query, format at end of the query would been added, format was not be specified correctly. This fix add format to end of path rather than query.
* | Merge pull request #23011 from arnvald/bugfix/correctly_parse_dateGodfrey Chan2016-06-253-7/+25
|\ \ | | | | | | | | | Use correct timezone when parsing date in json
| * | Use correct timezone when parsing date in jsonGrzegorz Witek2016-01-223-7/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes https://github.com/rails/rails/issues/22171 Time specified in ISO 8601 format without `Z` should be considered as local time, yet until now it was treated as UTC. This commit fixes problem by parsing time using timezone specified in application config. The downside of this solution is performance hit (`Time.zone.parse` is ~ 1.6x slower than `Time.parse`), so maybe there's a better solution.
* | | Merge pull request #25287 from marekkirejczyk/fix_25267Godfrey Chan2016-06-252-1/+8
|\ \ \ | | | | | | | | Make select_year work with include_position: true option, fix #25267
| * | | Make select_year work with include_position: true option, fix #25267Marek2016-06-052-1/+8
| | | |
* | | | Merge pull request #25476 from maclover7/jm-docs-dep-loadingJon Moss2016-06-241-1/+1
|\ \ \ \ | | | | | | | | | | Update grammar for `config.enable_dependency_loading` docs
| * | | | Update grammar for `config.enable_dependency_loading` docsJon Moss2016-06-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ci skip] r? @rafaelfranca
* | | | | Merge pull request #25517 from alexcameron89/per_thread_registryJon Moss2016-06-241-1/+1
|\ \ \ \ \ | |/ / / / |/| | | | [ci skip] Add link reference in ActiveSupport::PerThreadRegistry
| * | | | [ci skip] Add link to method referenced in ActiveSupport::PerThreadRegistryAlex Kitchens2016-06-241-1/+1
|/ / / /
* | | | Merge pull request #25514 from maclover7/jm-ar-nodocKasper Timm Hansen2016-06-241-1/+1
|\ \ \ \ | | | | | | | | | | nodoc `ActiveRecord::AttributeSet::YAMLEncoder`
| * | | | nodoc `ActiveRecord::AttributeSet::YAMLEncoder`Jon Moss2016-06-241-1/+1
|/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As mentioned in 7b86ea6715ee987e61a7f3bd8e72b1bbfcfbbbe7, this is an internal class. [ci skip] r? @sgrif
* | | | Revert "[ci skip] better docs for ↵Jon Moss2016-06-241-17/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ActiveRecord::AttributeSet::YAMLEncoder#decode" This reverts commit 7ea502ae141fc26b736c7a73bdf7a676b1f9fc87, per internal discussion with @sgrif -- this is documenting the implementation of a class that isn't intended to be public API.
* | | | Merge pull request #25506 from y-yagi/return_correct_from_enum_typeSean Griffin2016-06-242-0/+6
|\ \ \ \ | | | | | | | | | | return correct type from `EnumType`
| * | | | return correct type from `EnumType`yuuji.yaginuma2016-06-242-0/+6
| | | | |
* | | | | Merge pull request #25470 from alexcameron89/masterVipul A M2016-06-241-1/+12
|\ \ \ \ \ | | | | | | | | | | | | [ci skip] Add additional documentation to ActiveModel::Errors
| * | | | | [ci skip] Add additional documentation to ActiveModel::ErrorsAlex Kitchens2016-06-221-1/+12
| | | | | |
* | | | | | Merge pull request #25502 from Edouard-chin/exclusive-scope-test-residueRafael França2016-06-241-6/+0
|\ \ \ \ \ \ | | | | | | | | | | | | | | Removed a forgotten `with_exclusive_scope` test:
| * | | | | | Removed a forgotten `with_exclusive_scope` test:Edouard CHIN2016-06-241-6/+0
|/ / / / / / | | | | | | | | | | | | | | | | | | - `with_exclusive_scope` was removed in this commit d242e467819a428ad7e302968e4c9fa1e26d9326
* | | | | | Merge pull request #25478 from maclover7/jm-permitted-falseRafael França2016-06-232-0/+8
|\ \ \ \ \ \ | | | | | | | | | | | | | | `params.permitted?` is false by default
| * | | | | | `params.permitted?` is false by defaultJon Moss2016-06-232-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the docs: "+permit_all_parameters+ - If it's +true+, all the parameters will be permitted by default. The default is +false+."
* | | | | | | Merge pull request #25486 from alexcameron89/inheritanceJon Moss2016-06-231-1/+2
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | [ci skip] Update Documentation on ActiveRecord::Inheritance
| * | | | | | | [ci skip] Update Documentation on ActiveRecord::InheritanceAlex Kitchens2016-06-231-1/+2
| | |_|/ / / / | |/| | | | |
* | | | | | | Merge pull request #25485 from georgemillo/patch-1Jon Moss2016-06-231-1/+1
|\ \ \ \ \ \ \ | |_|/ / / / / |/| | | | | | English fix
| * | | | | | English fixGeorge Millo2016-06-231-1/+1
|/ / / / / / | | | | | | | | | | | | --skip-ci
* | | | | | Merge pull request #25480 from kmcphillips/masterRafael França2016-06-222-0/+11
|\ \ \ \ \ \ | |/ / / / / |/| | | | | Update changelog for ActiveSupport::Logger.broadcast #silence and config.assets.quiet = true
| * | | | | Update changelog for #25351Kevin McPhillips2016-06-221-0/+5
| | | | | |
| * | | | | Update changelog for #25341Kevin McPhillips2016-06-221-0/+6
|/ / / / /
* | | | | Initialize the configuration with a valueRafael Mendonça França2016-06-224-10/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will fix the failures fixed by 41488adbb89a09fa96188486f8414842ff28c848 and keep this new option that is semi-private outside of the generated configurations
* | | | | Merge pull request #25473 from ↵Jon Moss2016-06-221-19/+18
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | bquorning/update-documentation-for-strong_parameters Update documentation for strong parameters
| * | | | | Update ActionController::Parameters documentation [ci skip]Benjamin Quorning2016-06-221-19/+18
|/ / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The changes in this commit are twofold: 1. The examples showing `#require` accepting two arguments were wrong - you have to wrap the arguments (two, or more) in an array. 2. `ActionController::Parameters` has an `#inspect` method now (since https://github.com/rails/rails/pull/23732), and the documentation should reflect that.
* | | | | Fix failing railties testseileencodes2016-06-223-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | Railties tests didn't know about the new config option added in 80b416f so it needed to be added to the railties generators for configs.
* | | | | Add option to enable dependency loading in productionRafael Mendonça França2016-06-222-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will make easier to applications that rely on having const_missing hooks in production upgrade to Rails 5. This option is going to be remove in the future and the default behavior will be to disable the dependency loading.
* | | | | Merge pull request #25469 from ↵Rafael Mendonça França2016-06-226-139/+39
|\ \ \ \ \ | |/ / / / |/| | | | | | | | | | | | | | | | | | | herminiotorres/update-datetime-to-datetime-local-by-html-specification Change datetime to datetime-local helper tag
| * | | | Change datetime to datetime-local helper tagHerminio Torres2016-06-216-139/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A change was made in the helper that renders the `datetime`, being now by default `datetime-local` and creating an alias of `datetime-local` for `datetime`, `datetime` tag and it passes to be an abstract class for all other tags that inherit from him. As a new specification of the HTML 5 the text field type `datetime` will no longer exist and will pass a `datetime-local`. Ref: https://html.spec.whatwg.org/multipage/forms.html#local-date-and-time-state-(type=datetime-local)
* | | | | Merge pull request #25467 from aarongray/tweak_time_helpers_docs_for_time_zonesVipul A M2016-06-221-3/+3
|\ \ \ \ \ | |/ / / / |/| | | | Docs: create times using the rails timezone not system timezone [ci skip]
| * | | | Create times in rails timezone not system timezone [ci skip]aarongray2016-06-211-3/+3
|/ / / / | | | | | | | | | | | | | | | | | | | | Time.new is a Ruby method that uses system timezone. Traveling in time using it is a recipe for confusion. Instead, Time.zone.local should be used since it uses the Rails timezone.
* | | | Merge pull request #25464 from prathamesh-sonpatki/fix-http-requestRafael França2016-06-211-1/+1
|\ \ \ \ | | | | | | | | | | update_url is not `get` most of the times [ci skip]
| * | | | update_url is not `get` most of the times [ci skip]Prathamesh Sonpatki2016-06-221-1/+1
|/ / / /
* | | / Revert "Merge pull request #17973 from maurogeorge/file_field_hidden_field"eileencodes2016-06-213-53/+5
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The reason we are reverting this commit is because it created breaking changes for file upload gems. For more information see discussion here: https://github.com/rails/rails/issues/17947#issuecomment-225154294 This reverts commit c455817804e4df64c46c17a0cdec0e5a1ca5ba2e, reversing changes made to 8b3cd74b8a09ef85a43d7631bb062a9ec7f57227. Conflicts: actionview/CHANGELOG.md actionview/lib/action_view/helpers/form_helper.rb
* | | Change the raw template handler to render html-safe stringseileencodes2016-06-213-1/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In PR #24929 the changelog was updated to make note that while the new template handler was changed to raw this changed the behavior when outputting plain html or js files. Previously ERB would output the files unescaped. Changing the default handler to RAW meant that these same files would be rendered as escaped rather than as js or html. Because of this change in behavior and after the discussion #24949 in we decided to change the behavior of the Raw handler to output html_safe strings by default. Now files rendered with the default handler (raw) render the file unescaped.
* | | Merge pull request #25458 from ↵Jon Moss2016-06-211-0/+17
|\ \ \ | | | | | | | | | | | | | | | | | | | | taboularasa/taboularasa/update-docs-ActiveRecord__AttributeSet__YAMLEncoder#decode-for-pr better docs for ActiveRecord::AttributeSet::YAMLEncoder#decode
| * | | [ci skip] better docs for ActiveRecord::AttributeSet::YAMLEncoder#decodeDavid Elliott2016-06-211-0/+17
| | | |
* | | | Merge pull request #25415 from maclover7/jm-fix-25410Rafael França2016-06-211-0/+6
|\ \ \ \ | |/ / / |/| | | Add test to better demonstrate `ActiveModel::Errors#added?` behavior
| * | | Add test to better demonstrate `ActiveModel::Errors#added?` behaviorJon Moss2016-06-211-0/+6
| | | | | | | | | | | | | | | | Fixes #25410.
* | | | Merge pull request #25450 from prathamesh-sonpatki/fix-testing-guideKasper Timm Hansen2016-06-211-7/+11
|\ \ \ \ | | | | | | | | | | Fix the docs for supported keyword args or Rails 5 style integration controller tests [ci skip]