kill() method for trashing smith

This commit is contained in:
Daniel Lugo 2021-09-16 17:08:59 -04:00
parent b77ed72611
commit 3f8faa4daa

View file

@ -712,7 +712,7 @@ function createUserReplica() {
} }
/** /**
* @typedef {Smith.GunSmithNode & { reforge(): void }} RootNode * @typedef {Smith.GunSmithNode & { kill(): void }} RootNode
*/ */
/** /**
@ -727,8 +727,10 @@ const Gun = opts => {
// signature // signature
return { return {
...createReplica('$root'), ...createReplica('$root'),
reforge() { kill() {
forge() currentGun.send('bye')
currentGun.disconnect()
currentGun.kill()
} }
} }
} }