Skip to content

Commit

Permalink
Fabo/remove per block caching as not working (#247)
Browse files Browse the repository at this point in the history
* remove per block caching as not working

* fix memoized results

Co-authored-by: Ana G. <[email protected]>
  • Loading branch information
faboweb and Bitcoinera committed Jan 8, 2020
1 parent 7417c93 commit 69477d4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/block-listeners/cosmos-node-subscription.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ class CosmosNodeSubscription {
})
})

this.cosmosAPI.clearMemory()
this.cosmosAPI.memoizedResults.clear()
}

async getLatestBlockData() {
Expand Down
4 changes: 2 additions & 2 deletions lib/source/cosmosV0-source.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
const { PerBlockCacheDataSource } = require('./PerBlockCacheDataSource')
const { RESTDataSource } = require('apollo-datasource-rest')
const BigNumber = require('bignumber.js')
const _ = require('lodash')
const { uniqWith, sortBy, reverse } = require('lodash')
const { encodeB32, decodeB32, pubkeyToAddress } = require('../tools')
const { UserInputError } = require('apollo-server')

class CosmosV0API extends PerBlockCacheDataSource {
class CosmosV0API extends RESTDataSource {
constructor(network) {
super()
this.baseURL = network.api_url
Expand Down

0 comments on commit 69477d4

Please sign in to comment.