Skip to content

Commit

Permalink
refactor!: remove outdated destroyInstance method
Browse files Browse the repository at this point in the history
BREAKING CHANGE: `destroyInstance` method removed
It wasn't doing anything, just remove it's usages.
  • Loading branch information
davidyuk committed Jun 14, 2022
1 parent 56ca971 commit 0213375
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
7 changes: 0 additions & 7 deletions src/ae/index.ts
Expand Up @@ -46,13 +46,6 @@ export default stampit(NodePool, AccountResolver, {
setCompilerUrl (compilerUrl: string, { ignoreVersion = false } = {}): void {
this.compilerApi = new Compiler(compilerUrl, { ignoreVersion })
},
/**
* Remove all listeners for RPC
*/
destroyInstance (): void {
const destroyMethods = ['destroyClient', 'destroyServer']
destroyMethods.forEach((m) => typeof this[m] === 'function' && this[m]())
},
...mapObject<Function, Function>(
{
...spendMethods,
Expand Down
4 changes: 0 additions & 4 deletions test/integration/transaction.ts
Expand Up @@ -168,8 +168,4 @@ describe('Transaction', function () {
expect(await aeSdk.getAccountNonce(address)).to.be.equal(+accountNonce + 1)
expect(await aeSdk.getAccountNonce(address, { nonce: 1 })).to.be.equal(1)
})

it('Destroy instance finishes without error', () => {
aeSdk.destroyInstance()
})
})

0 comments on commit 0213375

Please sign in to comment.