Skip to content

Commit

Permalink
Be a good citizen and return method name from memo_wise
Browse files Browse the repository at this point in the history
This should allow to do chaining like:
```ruby
private memo_wise def foo
  42
end
```
  • Loading branch information
paracycle committed Dec 10, 2021
1 parent 200db6b commit 244562a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/memo_wise.rb
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,8 @@ def #{method_name}(#{MemoWise::InternalAPI.args_str(method)})
end

memo_wise_module.send(visibility, method_name)

method_name
end

# Override [Module#instance_method](https://ruby-doc.org/core-3.0.0/Module.html#method-i-instance_method)
Expand Down

0 comments on commit 244562a

Please sign in to comment.