Fix AddSupportedProofTypes

This commit is contained in:
Aayush Rajasekaran 2020-09-25 17:33:25 -04:00
parent 6db6a90b1e
commit d8431ff611

View File

@ -22,12 +22,10 @@ func SetSupportedProofTypes(types ...abi.RegisteredSealProof) {
// AddSupportedProofTypes sets supported proof types, across all actor versions.
// This should only be used for testing.
func AddSupportedProofTypes(types ...abi.RegisteredSealProof) {
newTypes := make(map[abi.RegisteredSealProof]struct{}, len(types))
for _, t := range types {
newTypes[t] = struct{}{}
// Set for all miner versions.
miner0.SupportedProofTypes[t] = struct{}{}
}
// Set for all miner versions.
miner0.SupportedProofTypes = newTypes
}
// SetPreCommitChallengeDelay sets the pre-commit challenge delay across all