0
0
Fork 0

Autofix Rubocop Rails/EnumHash (#23737)

This commit is contained in:
Nick Schonning 2023-02-19 23:00:36 -05:00 committed by GitHub
parent 44a7d87cb1
commit 63e6353886
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 12 additions and 28 deletions

View file

@ -24,7 +24,7 @@ class Import < ApplicationRecord
belongs_to :account
enum type: [:following, :blocking, :muting, :domain_blocking, :bookmarks]
enum type: { following: 0, blocking: 1, muting: 2, domain_blocking: 3, bookmarks: 4 }
validates :type, presence: true
validates_with ImportValidator, on: :create