This commit is contained in:
Ben Wilson
2023-07-25 22:45:14 -04:00
parent 3b583b3d67
commit d1ecffdea3
3 changed files with 28 additions and 1 deletions
+6
View File
@@ -387,10 +387,16 @@ export class StratumV1Client extends EasyUnsubscribe {
sessionId: this.extraNonceAndSessionId,
blockData: blockHex
});
await this.notificationService.notifySubscribersBlockFound(this.clientAuthorization.address, jobTemplate.blockData.height, updatedJobBlock, result);
//success
if (result == null) {
await this.addressSettingsService.resetBestDifficultyAndShares();
}
}
try {
await this.statistics.addSubmission(this.entity, submissionHash, this.sessionDifficulty);
await this.addressSettingsService.addShares(this.clientAuthorization.address, this.sessionDifficulty);
} catch (e) {
console.log(e);
const err = new StratumErrorMessage(