Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

removing round operator filter #3473

Merged
merged 1 commit into from
May 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions packages/common/src/allo/backends/allo-v2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -470,8 +470,6 @@ export class AlloV2 implements Allo {
this.chainId
);

console.log("args", args);

if (args.roundData.roundCategory === RoundCategory.QuadraticFunding) {
const initStrategyData: DonationVotingMerkleDistributionStrategyTypes.InitializeData =
{
Expand Down Expand Up @@ -540,16 +538,12 @@ export class AlloV2 implements Allo {
chain: this.chainId,
});

console.log("===> 1");

initStrategyDataEncoded =
await strategy.getInitializeData(initStrategyData);

const alloToken =
args.roundData.token === zeroAddress ? NATIVE : args.roundData.token;

console.log("===> 2", alloToken);

token = getAddress(alloToken);
} else if (args.roundData.roundCategory === RoundCategory.Direct) {
const initStrategyData: DirectGrantsLiteStrategyTypes.InitializeData = {
Expand Down Expand Up @@ -637,8 +631,6 @@ export class AlloV2 implements Allo {
),
};

console.log("createPoolArgs", createPoolArgs);

let txData: TransactionData;

if (
Expand Down
11 changes: 1 addition & 10 deletions packages/round-manager/src/features/api/round.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,21 +152,12 @@ export async function listRounds(args: {
}): Promise<{ rounds: Round[] }> {
const { chainId, dataLayer, programId } = args;

let rounds = await dataLayer
const rounds = await dataLayer
.getRoundsForManager({
chainId: chainId,
programId,
})
.then((rounds) => rounds.map(indexerV2RoundToRound));

// Filter out rounds where operatorWallets does not include round.createdByAddress
// This is to filter out spam rounds created by bots
rounds = rounds.filter((round) => {
return (
round.createdByAddress &&
round.operatorWallets?.includes(round.createdByAddress)
);
});

return { rounds };
}
Loading