Fix verification check logic

This commit is contained in:
HeesungB 2022-12-17 01:25:10 +09:00
parent 0944e5c175
commit 357b65b587

View File

@ -9,6 +9,18 @@ export const makeClaimMessage = (
verificationList: any[],
referral?: string,
): CosmwasmExecuteMessageResult => {
verificationList = verificationList.filter((verification) => {
if (verification.status !== "fulfilled") {
console.log("verification", verification);
}
return verification.status === "fulfilled";
});
if (verificationList.length === 0) {
throw new Error("Verifications rejected all");
}
return makeCosmwasmExecMsg(
senderAddress,
REGISTRAR_ADDRESS,