mirror of
https://github.com/benjamin-wilson/public-pool.git
synced 2026-09-29 09:05:06 -07:00
testNonceValue work
This commit is contained in:
@@ -15,7 +15,7 @@ export class MiningJob {
|
||||
public params: string[];
|
||||
|
||||
public target: string;
|
||||
public merkleRoot: Buffer;
|
||||
public merkleRoot: string;
|
||||
|
||||
public job_id: string; // ID of the job. Use this ID while submitting share generated from this job.
|
||||
public prevhash: string; // The hex-encoded previous block hash.
|
||||
@@ -31,6 +31,8 @@ export class MiningJob {
|
||||
|
||||
constructor(blockTemplate: IBlockTemplate) {
|
||||
|
||||
console.log(blockTemplate);
|
||||
|
||||
this.job_id = randomUUID();
|
||||
this.target = blockTemplate.target;
|
||||
this.prevhash = blockTemplate.previousblockhash;
|
||||
@@ -71,7 +73,7 @@ export class MiningJob {
|
||||
|
||||
this.merkle_branch = branch;
|
||||
|
||||
this.merkleRoot = tree.getRoot();
|
||||
this.merkleRoot = tree.getRoot().toString('hex')
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user