| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| |
| | |
Guard clause for id_kind in generator
|
| | |
|
| |
| |
| |
| | |
Also move the method to the right class
|
|/ |
|
|\
| |
| | |
Fix punctuation [ci skip]
|
| | |
|
|\ \
| |/
|/| |
Catch invalid UTF-8 querystring values and respond with BadRequest
|
|/ |
|
|\
| |
| |
| |
| | |
tgxworld/fix_random_error_when_running_tests_with_jruby
FIX: Randomly failing test when running without GIL.
|
| | |
|
|\ \
| | |
| | | |
Remove no need `binds.empty?` checking
|
| |/
| |
| |
| |
| | |
`#exec_stmt` is private method and only called in `#exec_query`. it
means `binds` is provided always. No need `binds.empty?` checking.
|
|\ \
| | |
| | |
| | |
| | | |
y-yagi/remove_unnecessary_files_indummy_application
remove unnecessary readme in dummy application
|
| |/
| |
| |
| | |
`README` it is changed to `README.rdoc` in 6b126e2, it has been changed to` README.md` further 89a12c9.
|
|\ \
| |/
|/| |
[ci skip] Add more code examples for `Module#anonymous?` docs
|
|/
|
|
|
| |
In later code examples, it is better to write how `Module#anonymous?`
works.
|
| |
|
|
|
|
|
|
|
|
| |
Reason: That one is an Oxford comma, as per our guidelines. See:
http://edgeguides.rubyonrails.org/api_documentation_guidelines.html#comma
This reverts commit f184cd34f9ef35ddf85a23c2fb02cc05d3fb26b3.
|
|\
| |
| | |
[ci skip] removed extra comma
|
|/ |
|
|
|
|
| |
[ci skip]
|
|\
| |
| | |
Use sufficient a regexp anchor to check `@response.content_type.to_s`
|
| |
| |
| |
| |
| |
| | |
This commit follows up of ea9bc06c9a47b839d5e2db94ba6bf7e29c8f0ae9.
To check `@response.content_type.to_s` is ended with `"xml"`,
to use `\z` is sufficient.
|
|\ \
| | |
| | | |
Refactored association preloader for performance
|
| | |
| | |
| | |
| | |
| | | |
* less arrays created
* less complexity with only one level of nesting in loop
|
|\ \ \
| |_|/
|/| | |
Change Integer#year to return a Fixnum instead of a Float to improve consistency
|
| | | |
|
|\ \ \
| |/ /
|/| | |
Suppress warnings (warnings about AD::IntegrationTest HTTP request)
|
|/ /
| |
| |
| |
| | |
These warings have been appeared from
ea9bc06c9a47b839d5e2db94ba6bf7e29c8f0ae9.
|
|\ \
| | |
| | |
| | |
| | | |
rafaelsales/issues/21922-fix-ar-group-by-attribute-lookup
Fix generated projection fields in group by query
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
* When tried to use `Company#accounts` test/models/company.rb I got:
```
ActiveRecord::StatementInvalid: SQLite3::SQLException: no such column:
accounts.company_id: SELECT COUNT(*) AS count_all, "companies"."firm_id"
AS companies_firm_id FROM "companies" INNER JOIN "accounts" ON
"accounts"."company_id" = "companies"."id" GROUP BY "companies"."firm_id"
```
* The refactor on Calculations class was just to simplify the code
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Closes #21922
Let `Book(id, author_id)`, `Photo(id, book_id, author_id)` and `Author(id)`
Running `Book.group(:author_id).joins(:photos).count` will produce:
* Rails 4.2 - conflicts `author_id` in both projection and group by:
```sql
SELECT COUNT(*) AS count_all, author_id AS author_id
FROM "books" INNER JOIN "photos" ON "photos"."book_id" = "books"."id"
GROUP BY author_id
```
* Master (9d02a25) - conflicts `author_id` only in projection:
```sql
SELECT COUNT(*) AS count_all, author_id AS author_id
FROM "books" INNER JOIN "photos" ON "photos"."book_id" = "books"."id"
GROUP BY "books"."author_id"
```
* With this fix:
```sql
SELECT COUNT(*) AS count_all, "books"."author_id" AS books_author_id
FROM "books" INNER JOIN "photos" ON "photos"."book_id" = "books"."id"
GROUP BY "books"."author_id"
```
|
|\ \ \
| |/ /
|/| | |
Remove `#tables` extra args again
|
|/ /
| |
| |
| |
| |
| | |
This issue was resolved by #21687 already. But re-add args by #18856.
`#tables` extra args was only using by `#table_exists?`. This is for
internal API. This commit will remove these extra args again.
|
|\ \
| | |
| | | |
remove unnecessary forwardable require
|
|/ /
| |
| | |
`Forwardable` has been used in the past
|
|\ \
| | |
| | | |
Extract native getter to attr_reader.
|
| | |
| | |
| | |
| | |
| | | |
The getter is doing nothing more than returning the ivar, so it can be
extracted to an attr_reader.
|
|\ \ \
| |/ /
|/| | |
Fix warnings in multiple application tests
|
|/ /
| |
| |
| |
| | |
This is primarily to fix method redefinition warnings in class_attribute
but may be of use in other places where we define singleton methods.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
[ci skip]
It's been a source of confusion that the lower-level `add_column`
referenced the higher level `column` method for available options.
`column` supports additional functionality like `index: true` that is
not present on `add_column`.
This patch moves common option documentation to `add_column` and only
documents the additional options in `column`.
|
|\ \
| | |
| | | |
typo
|
|/ / |
|
| |
| |
| |
| |
| |
| |
| | |
Ok, this explains why the branch showed as green. We don't run files in
isolation for PRs, only for master. Active Support monkeypatches
`BigDecimal#to_s`, so the generated error message was different
depending on if the file was run in isolation
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The error message when asserting `greater_than: BigDecimal.new` will
give an error message based on how BigDecimal displays itself. Big
decimal appears to always use scientific notation. This might not be the
best error message for the general case, but the general case wouldn't
use big decimal for the validation. And if they do, they likely need
this level of precision.
|
|\ \
| | |
| | | |
Revert " Added an example to show how common secrets can be shared ac…
|
|/ /
| |
| |
| | |
multiple environments in secrets.yml"
|
|\ \
| | |
| | | |
Use the post-type-cast version of the attribute to validate numericality
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This fixes the issue where you may be comparing (using a numeric
validator such as `greater_than`) numbers of a specific Numeric type
such as `BigDecimal`.
Previous behavior took the numeric value to be validated and
unconditionally converted to Float. For example, due to floating point
precision, this can cause issues when comparing a Float to a BigDecimal.
Consider the following:
```
validates :sub_total, numericality: {
greater_than: BigDecimal('97.18')
}
```
If the `:sub_total` value BigDecimal.new('97.18') was validated against
the above, the following would be valid since `:sub_total` is converted
to a Float regardless of its original type. The result therefore becomes
Kernel.Float(97.18) > BigDecimal.new('97.18')
The above illustrated behavior is corrected with this patch by
conditionally converting the value to validate to float.
Use the post-type-cast version of the attribute to validate numericality
[Roque Pinel & Trevor Wistaff]
|
|\ \ \
| | | |
| | | | |
FileStore: Long cache keys may result in too long paths due to encoding
|