mirror of
https://github.com/d0zingcat/gocryptotrader.git
synced 2026-05-13 15:09:42 +00:00
(Engine) Variety of engine updates (#390)
* drop common uuid v4 func and imported package as needed * removed common functions regarding json marshal and unmarshal and used the json package directly. WRT unmarshal it was calling reflect and converted to string which is also checked in the JSON package so it was doing a double up, this will be a tiny gain as it was directly used in the requester package for all our outbound requests. * add in string * explicitly throw away return error value * atleast return the error that websocket initialise returns * return error when not connected * fix comment * Adds comments * move package declarations * drop append whenever we call supported * remove unused import * Change incorrect spelling * fix tests * fix go import issue
This commit is contained in:
committed by
Adrian Gallagher
parent
c27b8657e2
commit
0c5d75b22c
@@ -5,6 +5,7 @@ import (
|
||||
"crypto/aes"
|
||||
"crypto/cipher"
|
||||
"crypto/rand"
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
"io"
|
||||
@@ -168,7 +169,7 @@ func DecryptConfigFile(configData, key []byte) ([]byte, error) {
|
||||
|
||||
// ConfirmConfigJSON confirms JSON in file
|
||||
func ConfirmConfigJSON(file []byte, result interface{}) error {
|
||||
return common.JSONDecode(file, &result)
|
||||
return json.Unmarshal(file, &result)
|
||||
}
|
||||
|
||||
// ConfirmSalt checks whether the encrypted data contains a salt
|
||||
|
||||
Reference in New Issue
Block a user