File tree Expand file tree Collapse file tree 7 files changed +12
-16
lines changed Expand file tree Collapse file tree 7 files changed +12
-16
lines changed Original file line number Diff line number Diff line change @@ -226,6 +226,9 @@ Rails/BelongsTo:
226
226
Description : >-
227
227
Use `optional: true` instead of `required: false` for
228
228
`belongs_to` relations.
229
+ Reference :
230
+ - https://guides.rubyonrails.org/5_0_release_notes.html
231
+ - https://github.com/rails/rails/pull/18937
229
232
Enabled : true
230
233
VersionAdded : ' 0.62'
231
234
@@ -244,6 +247,9 @@ Rails/Blank:
244
247
245
248
Rails/BulkChangeTable :
246
249
Description : ' Check whether alter queries are combinable.'
250
+ Reference :
251
+ - https://api.rubyonrails.org/classes/ActiveRecord/ConnectionAdapters/SchemaStatements.html#method-i-change_table
252
+ - https://api.rubyonrails.org/classes/ActiveRecord/ConnectionAdapters/Table.html
247
253
Enabled : true
248
254
VersionAdded : ' 0.57'
249
255
Database : null
@@ -592,6 +598,9 @@ Rails/Inquiry:
592
598
593
599
Rails/InverseOf :
594
600
Description : ' Checks for associations where the inverse cannot be determined automatically.'
601
+ Reference :
602
+ - https://guides.rubyonrails.org/association_basics.html#bi-directional-associations
603
+ - https://api.rubyonrails.org/classes/ActiveRecord/Associations/ClassMethods.html#module-ActiveRecord::Associations::ClassMethods-label-Setting+Inverses
595
604
Enabled : true
596
605
VersionAdded : ' 0.52'
597
606
IgnoreScopes : false
@@ -1042,6 +1051,8 @@ Rails/TopLevelHashWithIndifferentAccess:
1042
1051
1043
1052
Rails/TransactionExitStatement :
1044
1053
Description : ' Avoid the usage of `return`, `break` and `throw` in transaction blocks.'
1054
+ Reference :
1055
+ - https://github.com/rails/rails/commit/15aa4200e083
1045
1056
Enabled : pending
1046
1057
VersionAdded : ' 2.14'
1047
1058
Original file line number Diff line number Diff line change @@ -47,9 +47,6 @@ module Rails
47
47
# class Post < ApplicationRecord
48
48
# belongs_to :blog, optional: false
49
49
# end
50
- #
51
- # @see https://guides.rubyonrails.org/5_0_release_notes.html
52
- # @see https://github.com/rails/rails/pull/18937
53
50
class BelongsTo < Base
54
51
extend AutoCorrector
55
52
extend TargetRailsVersion
Original file line number Diff line number Diff line change @@ -62,9 +62,6 @@ module Rails
62
62
# t.string :nickname
63
63
# end
64
64
# end
65
- #
66
- # @see https://api.rubyonrails.org/classes/ActiveRecord/ConnectionAdapters/SchemaStatements.html#method-i-change_table
67
- # @see https://api.rubyonrails.org/classes/ActiveRecord/ConnectionAdapters/Table.html
68
65
class BulkChangeTable < Base
69
66
MSG_FOR_CHANGE_TABLE = <<~MSG . chomp
70
67
You can combine alter queries using `bulk: true` options.
@@ -216,7 +213,7 @@ def support_bulk_alter?
216
213
true
217
214
when POSTGRESQL
218
215
# Add bulk alter support for PostgreSQL in 5.2.0
219
- # @see https://github.com/rails/rails/pull/31331
216
+ # See: https://github.com/rails/rails/pull/31331
220
217
target_rails_version >= 5.2
221
218
else
222
219
false
Original file line number Diff line number Diff line change @@ -35,8 +35,6 @@ module Rails
35
35
# skip_before_action :login_required,
36
36
# if: -> { trusted_origin? && action_name != "admin" }
37
37
# end
38
- #
39
- # @see https://api.rubyonrails.org/classes/AbstractController/Callbacks/ClassMethods.html#method-i-_normalize_callback_options
40
38
class IgnoredSkipActionFilterOption < Base
41
39
MSG = <<~MSG . chomp . freeze
42
40
`%<ignore>s` option will be ignored when `%<prefer>s` and `%<ignore>s` are used together.
Original file line number Diff line number Diff line change @@ -137,9 +137,6 @@ module Rails
137
137
# class Blog < ApplicationRecord
138
138
# has_many :posts, -> { order(published_at: :desc) }
139
139
# end
140
- #
141
- # @see https://guides.rubyonrails.org/association_basics.html#bi-directional-associations
142
- # @see https://api.rubyonrails.org/classes/ActiveRecord/Associations/ClassMethods.html#module-ActiveRecord::Associations::ClassMethods-label-Setting+Inverses
143
140
class InverseOf < Base
144
141
SPECIFY_MSG = 'Specify an `:inverse_of` option.'
145
142
NIL_MSG = 'You specified `inverse_of: nil`, you probably meant to use `inverse_of: false`.'
Original file line number Diff line number Diff line change @@ -173,8 +173,6 @@ module Rails
173
173
# def change
174
174
# remove_index :users, column: :email
175
175
# end
176
- #
177
- # @see https://api.rubyonrails.org/classes/ActiveRecord/Migration/CommandRecorder.html
178
176
class ReversibleMigration < Base
179
177
include MigrationsHelper
180
178
Original file line number Diff line number Diff line change @@ -45,8 +45,6 @@ module Rails
45
45
# # Commit
46
46
# next if user.active?
47
47
# end
48
- #
49
- # @see https://github.com/rails/rails/commit/15aa4200e083
50
48
class TransactionExitStatement < Base
51
49
MSG = <<~MSG . chomp
52
50
Exit statement `%<statement>s` is not allowed. Use `raise` (rollback) or `next` (commit).
You can’t perform that action at this time.
0 commit comments