From af41c88b244d490f64eb1e5c41b820e14f0725dd Mon Sep 17 00:00:00 2001 From: Nishaad Ajani Date: Fri, 15 Mar 2019 13:10:57 +0800 Subject: [PATCH] code cleanup --- snowflake.go | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/snowflake.go b/snowflake.go index fd34ef7..8d17e10 100644 --- a/snowflake.go +++ b/snowflake.go @@ -100,11 +100,7 @@ func NewNode(node int64) (*Node, error) { return nil, errors.New("Node number must be between 0 and " + strconv.FormatInt(nodeMax, 10)) } - return &Node{ - // time: 0, - node: node, - step: 0, - }, nil + return &Node{node: node}, nil } // Generate creates and returns a unique snowflake ID