Commit 5eb9837 1 parent 1118589 commit 5eb9837 Copy full SHA for 5eb9837
File tree 2 files changed +11
-1
lines changed
packages/common/src/constraints
2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -62,7 +62,11 @@ export const checkCandidate = async (
62
62
) ;
63
63
}
64
64
65
- const identityValid = await checkIdentity ( constraints . chaindata , candidate ) ;
65
+ const identityValid = await checkIdentity (
66
+ constraints . config ,
67
+ constraints . chaindata ,
68
+ candidate
69
+ ) ;
66
70
if ( ! identityValid ) {
67
71
logger . info ( `${ candidate . name } identity not valid` , constraintsLabel ) ;
68
72
}
Original file line number Diff line number Diff line change @@ -203,10 +203,16 @@ export const checkConnectionTime = async (
203
203
} ;
204
204
205
205
export const checkIdentity = async (
206
+ config : Config . ConfigSchema ,
206
207
chaindata : ChainData ,
207
208
candidate : Candidate ,
208
209
) : Promise < boolean > => {
209
210
try {
211
+ const skipIdentity = config . constraints ?. skipIdentity || false ;
212
+ if ( skipIdentity ) {
213
+ await setIdentityInvalidity ( candidate , true ) ;
214
+ return true ;
215
+ }
210
216
const [ hasIdentity , verified ] = await chaindata . hasIdentity (
211
217
candidate . stash ,
212
218
) ;
You can’t perform that action at this time.
0 commit comments