Skip to content

Commit

Permalink
🧹 Manually overriding#model_name is a bit odd
Browse files Browse the repository at this point in the history
Instead, we use the mixin as a kind of
"nod-to-the-odd"
  • Loading branch information
zspencer committed Mar 25, 2024
1 parent 3bfafe0 commit 1043054
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions app/furniture/tobias/record.rb
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
class Tobias
class Record < ApplicationRecord
self.abstract_class = true
extend StripsNamespaceFromModelName

def self.model_name
@_model_name ||= ActiveModel::Name.new(self, ::Tobias)
end
end
end

0 comments on commit 1043054

Please sign in to comment.