- 20 5月, 2020 2 次提交
-
-
由 Aaron Patterson 提交于
Add DidYouMean for ParameterMissing
-
由 eileencodes 提交于
Journey is a private API that we want to refactor. We need to stop calling methods directly on it so we're free to change the implmentation.
-
- 19 5月, 2020 12 次提交
-
-
由 Aaron Patterson 提交于
Add DidYouMean for HasManyThroughAssociationNotFoundError
-
由 Petrik 提交于
If a parameter isn't found we can suggest similar params: ``` class BooksController < ActionController::Base def create params.require(:book).require(:name) head :ok end end post :create, params: { magazine: { name: "Mjallo!" } } param is missing or the value is empty: book Did you mean? controller action magazine post :create, params: { book: { title: "Mjallo!" } } param is missing or the value is empty: name Did you mean? title ```
-
由 Petrik 提交于
If a has_many :through association isn't found we can suggest similar associations: ``` class Author has_many :categorizations, -> { } has_many :categories, through: :categorizations has_many :categorized_posts, through: :categorizations, source: :post has_many :category_post_comments, through: :categories, source: :post_comments has_many :nothings, through: :kateggorisatons, class_name: "Category" end Author.first.nothings Could not find the association :kateggorisatons in model Author Did you mean? categorizations categories categorized_posts category_post_comments ```
-
由 Vitalii Khustochka 提交于
* Update `fixture_file_upload` documentation to reflect recent changes. [ci skip] * Friendlier deprecation message for `fixture_file_upload`. Suggested change now can be copied and pasted into the code without modification.
-
由 Ryuta Kamizono 提交于
-
由 Jonathan Hefner 提交于
Fix references in the form builders guide [ci skip]
-
由 Jamie 提交于
I caught two references that seemed inconsistent: 1. In section 2.2 Binding a Form to an Object, the code snippet variable was called `form`, but in the bullet points below, it was referenced as `f`. 2. In section 6 Uploading Files, the references to the params hash returned by two different forms was incorrect.
-
由 Ryuta Kamizono 提交于
Unify the query values normalization for multiple values
-
由 Ryuta Kamizono 提交于
That test requires Marshal is prepended by `MarshalWithAutoloading`.
-
由 Aaron Patterson 提交于
Use DidYouMean for ActionNotFound
-
由 Ryuta Kamizono 提交于
Currently the query values normalization for multiple values is missing some parts. Some values are flatten, but others are not flatten. Some values are compact, but others are not compact. some values are compact_blank, but others are not compact_blank. Originally all multiple values should be flatten and compact_blank before `build_arel`, if it is not ensured which multiple values are normalized or not, we need to normalize it again carefully and conservatively in `build_arel`. To unify the query values normalization for multiple values, ensure the normalization in `check_if_method_has_arguments!` since all multiple values should be checked by the method.
-
由 Ryuta Kamizono 提交于
-
- 18 5月, 2020 25 次提交
-
-
由 Aaron Patterson 提交于
* master-sec: Check that request is same-origin prior to including CSRF token in XHRs HMAC raw CSRF token before masking it, so it cannot be used to reconstruct a per-form token activesupport: Avoid Marshal.load on raw cache value in RedisCacheStore activesupport: Avoid Marshal.load on raw cache value in MemCacheStore Return self when calling #each, #each_pair, and #each_value instead of the raw @parameters hash Include Content-Length in signature for ActiveStorage direct upload
-
由 Petrik 提交于
If an action isn't found on a controller we can suggest similar actions: ``` The action 'indx' could not be found for SimpleController Did you mean? index ```
-
由 Ryuta Kamizono 提交于
Fix merging NOT IN clause to behave the same as before
-
由 Ryuta Kamizono 提交于
`HomogeneousIn` has changed merging behavior for NOT IN clause from before. This changes `equality?` to return true only if `type == :in` to restore the original behavior.
-
由 Ryuta Kamizono 提交于
Should not substitute binds when `prepared_statements: true`
-
由 Ryuta Kamizono 提交于
Support merging option `:rewhere` to allow mergee side condition to be replaced exactly
-
由 Ryuta Kamizono 提交于
Related #39236. `relation.merge` method sometimes replaces mergee side condition, but sometimes maintain both conditions unless `relation.rewhere` is used. It is very hard to predict merging result whether mergee side condition will be replaced or not. One existing way is to use `relation.rewhere` for merger side relation, but it is also hard to predict a relation will be used for `merge` in advance, except one-time relation for `merge`. To address that issue, I propose to support merging option `:rewhere`, to allow mergee side condition to be replaced exactly. That option will allow non-`rewhere` relation behaves as `rewhere`d relation. ```ruby david_and_mary = Author.where(id: david.id..mary.id) # both conflict conditions exists david_and_mary.merge(Author.where(id: bob)) # => [] # mergee side condition is replaced by rewhere david_and_mary.merge(Author.rewhere(id: bob)) # => [bob] # mergee side condition is replaced by rewhere option david_and_mary.merge(Author.where(id: bob), rewhere: true) # => [bob] ```
-
由 Ryuta Kamizono 提交于
Fix update with dirty locking column to not match latest object accidentally
-
由 Ryuta Kamizono 提交于
Fix rename column in bulk alter table for PostgreSQL
-
由 Ryuta Kamizono 提交于
PostgreSQL doesn't support rename column operation in bulk alter table. Fixes #39322.
-
由 Ryuta Kamizono 提交于
Related #32163. We should not identify an object by dirty value. If do so, accidentally matches latest object even though it is a stale object.
-
由 John Hawthorn 提交于
Skip interpolated strings in AV::Digestor
-
由 Ryuta Kamizono 提交于
Unless explicitly intend to behave it differently from the superclass.
-
由 Ryuta Kamizono 提交于
-
由 Aaron Patterson 提交于
Use DidYouMean for AssociationNotFoundError
-
由 Ryuta Kamizono 提交于
-
由 John Hawthorn 提交于
-
由 Eugene Kenny 提交于
Avoid allocating extra hash and arrays when as_json is called without options
-
由 fatkodima 提交于
Co-authored-by: NEugene Kenny <elkenny@gmail.com>
-
由 Petrik 提交于
If an association isn't found we can suggest matching associations: ``` Post.all.merge!(includes: :monkeys).find(6) Association named 'monkeys' was not found on Post; perhaps you misspelled it? Did you mean? funky_tags comments images skimmers ```
-
由 Ryuta Kamizono 提交于
In aggregation value's type cast, `klass.attribute_types.fetch(...)` will find no type almost all cases, since any type is already returned by `column.type_caster` in that case. And also, the root of join dependency tree is also the model's `klass`, so the explicit `klass.attribute_types` is redundant originally.
-
由 David Heinemeier Hansson 提交于
Add support for finding records based on signed ids, which are tamper-proof, verified ids that can be set to expire and scoped with a purpose. This is particularly useful for things like password reset or email verification, where you want the bearer of the signed id to be able to interact with the underlying record, but usually only within a certain time period.
-
由 Ryuta Kamizono 提交于
Otherwise `@_defer_touch_attrs` is touched again with old `@_touch_time` in `before_committed!`.
-
由 Vinicius Stock 提交于
* Use app:binstub:yarn in Action Text install generator
-
由 Ryuta Kamizono 提交于
Remove `sync_with_transaction_state` to simplify code base
-
- 17 5月, 2020 1 次提交
-
-
由 David Heinemeier Hansson 提交于
* Add default ENV variable option with BACKTRACE to turn off backtrace cleaning when debugging framework code * Use runner as the example Although I think we should consider dropping -b in tests and just relying on this more general option for sidestepping the backtrace cleaner.
-