Skip to content

Commit

Permalink
Rename to NewAdapterWithKey().
Browse files Browse the repository at this point in the history
  • Loading branch information
hsluoyz committed Jun 13, 2019
1 parent b36d844 commit 14d1caf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions adapter.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func finalizer(a *Adapter) {
a.conn.Close()
}

func newAdapter(network, address, key string) *Adapter {
func newAdapter(network string, address string, key string) *Adapter {
a := &Adapter{}
a.network = network
a.address = address
Expand All @@ -68,8 +68,8 @@ func NewAdapter(network string, address string) *Adapter {
return newAdapter(network, address, "casbin_rules")
}

// NewRedisAdapter is the constructor for Adapter.
func NewRedisAdapter(network, address, key string) *Adapter {
// NewAdapterWithKey is the constructor for Adapter.
func NewAdapterWithKey(network string, address string, key string) *Adapter {
return newAdapter(network, address, key)
}

Expand Down

0 comments on commit 14d1caf

Please sign in to comment.