mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-13 23:16:45 +00:00
currency: boost retrieval speed when calling currency.NewCode() (#1014)
* currency: optimization pass * currency: reimplement and fix tests and run benchmark comparison * Update currency/code_test.go Co-authored-by: Scott <gloriousCode@users.noreply.github.com> * glorious: nits * glorious: nits Co-authored-by: Ryan O'Hara-Reid <ryan.oharareid@thrasher.io> Co-authored-by: Scott <gloriousCode@users.noreply.github.com>
This commit is contained in:
@@ -28,7 +28,7 @@ type Role uint8
|
||||
|
||||
// BaseCodes defines a basket of bare currency codes
|
||||
type BaseCodes struct {
|
||||
Items []*Item
|
||||
Items map[string][]*Item
|
||||
LastMainUpdate time.Time
|
||||
mtx sync.Mutex
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user