Integrate SP auctions for app deployment #2
@ -319,13 +319,17 @@ export class Service {
|
|||||||
|
|
||||||
if (completedAuctionIds) {
|
if (completedAuctionIds) {
|
||||||
const projectsToBedeployed = projects.filter((project) =>
|
const projectsToBedeployed = projects.filter((project) =>
|
||||||
completedAuctionIds.includes(project.auctionId!) && project.deployerLrns !== null
|
completedAuctionIds.includes(project.auctionId!)
|
||||||
);
|
);
|
||||||
|
|
||||||
for (const project of projectsToBedeployed) {
|
for (const project of projectsToBedeployed) {
|
||||||
log(`Auction ${project!.auctionId} completed`);
|
log(`Auction ${project!.auctionId} completed`);
|
||||||
|
|
||||||
const deployerLrns = await this.laconicRegistry.getAuctionWinningDeployers(project!.auctionId!);
|
const deployerLrns = await this.laconicRegistry.getAuctionWinningDeployers(project!.auctionId!);
|
||||||
|
|
||||||
|
if (!deployerLrns) {
|
||||||
|
log(`No winning deployer for auction ${project!.auctionId}`);
|
||||||
|
} else {
|
||||||
// Update project with deployer LRNs
|
// Update project with deployer LRNs
|
||||||
await this.db.updateProjectById(project.id!, {
|
await this.db.updateProjectById(project.id!, {
|
||||||
deployerLrns
|
deployerLrns
|
||||||
@ -337,6 +341,7 @@ export class Service {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
this.deployRecordCheckTimeout = setTimeout(() => {
|
this.deployRecordCheckTimeout = setTimeout(() => {
|
||||||
this.checkAuctionStatus();
|
this.checkAuctionStatus();
|
||||||
|
Loading…
Reference in New Issue
Block a user