class Milestoner::Commits::Enrichers::Author
Enriches a commit author by using cache.
Attributes
Public Class Methods
Source
# File lib/milestoner/commits/enrichers/author.rb, line 10 def initialize(model: Models::User, **) super(**) @model = model end
Calls superclass method
Public Instance Methods
Source
# File lib/milestoner/commits/enrichers/author.rb, line 15 def call commit cache.read(:users) { |table| table.find commit.author_name } .value_or(model.new) end