This commit is contained in:
2021-04-10 09:36:02 -05:00
parent a3c60a1951
commit 71b4fefef7

View File

@@ -26,6 +26,9 @@ export class Blockchain extends Controller {
})) }))
} }
/**
* Determine whether the current blockchain is valid.
*/
public async validate() { public async validate() {
const blocks = (await this.blockchain.read()).map(x => new Block(x)) const blocks = (await this.blockchain.read()).map(x => new Block(x))
return { return {