mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-20 10:52:25 +00:00
optional external extra field
This commit is contained in:
parent
25507e068a
commit
c812ada6fd
1 changed files with 5 additions and 1 deletions
|
|
@ -937,7 +937,11 @@ func (w *worker) prepareWork(genParams *generateParams) (*environment, error) {
|
||||||
}
|
}
|
||||||
// Set the extra field.
|
// Set the extra field.
|
||||||
if len(w.extra) != 0 {
|
if len(w.extra) != 0 {
|
||||||
header.Extra = w.extra
|
if len(genParams.extra) != 0 {
|
||||||
|
header.Extra = genParams.extra
|
||||||
|
} else {
|
||||||
|
header.Extra = w.extra
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// Set the randomness field from the beacon chain if it's available.
|
// Set the randomness field from the beacon chain if it's available.
|
||||||
if genParams.random != (common.Hash{}) {
|
if genParams.random != (common.Hash{}) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue