Closed khiemfle closed 3 years ago
May I ask why don't we use the method init() anywhere?
https://github.com/bwmarrin/snowflake/blob/c09e69ae59935edf6d85799e858c26de86b04cb3/snowflake.go#L59
init() is a magic function of sorts that Go uses on it's own. That function is called by the go runtime when the application launches. It just does some basic initialization that needs to be done.
May I ask why don't we use the method init() anywhere?
https://github.com/bwmarrin/snowflake/blob/c09e69ae59935edf6d85799e858c26de86b04cb3/snowflake.go#L59