From 2872a9812449e685eadd98d66882b6975612ecc1 Mon Sep 17 00:00:00 2001 From: Dave Verwer Date: Tue, 14 Nov 2023 14:36:49 +0000 Subject: [PATCH] Made the incoming funding link data from GitHub optional. --- Sources/App/Commands/Ingest.swift | 2 +- Sources/App/Core/Github.swift | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Sources/App/Commands/Ingest.swift b/Sources/App/Commands/Ingest.swift index 797aca1ff2..c323c4cebd 100644 --- a/Sources/App/Commands/Ingest.swift +++ b/Sources/App/Commands/Ingest.swift @@ -200,7 +200,7 @@ func updateRepository(on database: Database, repository.defaultBranch = repoMetadata.defaultBranch repository.forks = repoMetadata.forkCount - repository.fundingLinks = repoMetadata.fundingLinks + repository.fundingLinks = repoMetadata.fundingLinks ?? [] repository.homepageUrl = repoMetadata.homepageUrl?.trimmed repository.isArchived = repoMetadata.isArchived repository.isInOrganization = repoMetadata.isInOrganization diff --git a/Sources/App/Core/Github.swift b/Sources/App/Core/Github.swift index 3c7c7bfd85..d86f20469c 100644 --- a/Sources/App/Core/Github.swift +++ b/Sources/App/Core/Github.swift @@ -389,7 +389,7 @@ extension Github { var defaultBranchRef: DefaultBranchRef? var description: String? var forkCount: Int - var fundingLinks: [FundingLink] + var fundingLinks: [FundingLink]? var homepageUrl: String? var isArchived: Bool // periphery:ignore