func (cl *OpencxRPC) GetPrice(args GetPriceArgs, reply *GetPriceReply) (err error) {
	cl.Server.LockIngests()
	// reply.Price = cl.Server.OpencxDB.GetPrice(args.TradingPair.String())

	if reply.Price, err = cl.Server.OpencxDB.CalculatePrice(args.TradingPair); err != nil {
		cl.Server.UnlockIngests()
		err = fmt.Errorf("Error calculating price: \n%s", err)
		return
	}
	cl.Server.UnlockIngests()
	return
}
// GetPrice returns the price for the specified asset
GetPrice returns the price for the specified asset
// GetPrice returns the price for the specified asset
func (cl *OpencxRPC) GetPrice(args GetPriceArgs, reply *GetPriceReply) (err error) {
	cl.Server.LockIngests()
	if reply.Price, err = cl.Server.OpencxDB.CalculatePrice(args.TradingPair); err != nil {
		cl.Server.UnlockIngests()
		err = fmt.Errorf("Error calculating price: \n%s", err)
		return
	}
	cl.Server.UnlockIngests()
	return
}
func ( cl * OpencxRPC ) GetPrice ( args GetPriceArgs , reply * GetPriceReply ) ( err error ) { cl . Server . LockIngests ( ) if reply . Price , err = cl . Server . OpencxDB . CalculatePrice ( args . TradingPair ) ; err != nil { cl . Server . UnlockIngests ( ) err = fmt . Errorf ( " \n " , err ) return } cl . Server . UnlockIngests ( ) return }
GetPrice returns the price for the specified asset
GetPrice returns the price for the specified asset
// reply.Price = cl.Server.OpencxDB.GetPrice(args.TradingPair.String())