samber / do

⚙️ A dependency injection toolkit based on Go 1.18+ Generics.
https://pkg.go.dev/github.com/samber/do
MIT License
1.82k stars 75 forks source link

chore: reuse existing code #40

Closed aFlyBird0 closed 1 year ago

aFlyBird0 commented 1 year ago

Hi, @samber !

Thank you for your do, lo, and mo. I really enjoy using them, both as a library user and for learning from the source code, they have been very helpful.

During the process of reading the source code, I found two places where slight modifications can make the code more organized. (I hope my changes can bring positive improvements to the code and not go against the original intention. Thank you!)

(By looking at these screenshots, it should be more intuitive to see the code changes compared to viewing them on the GitHub web page.)

image

image

samber commented 1 year ago

sure!