Skip to content

Commit

Permalink
Merge pull request #13 from pixyzehn/fix-flat-map-publisher
Browse files Browse the repository at this point in the history
Update 'flatMapPublisher' to 'flatMapLatestPublisher'
  • Loading branch information
melle authored Jun 26, 2023
2 parents 6b2831d + aab30ba commit d0b1cdb
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -30,18 +30,18 @@ struct GeneratePlist: ParsableCommand {
.mapResult { $0.ignoring(packages: (ignore ?? "").components(separatedBy: ",")) }
.mapResult(extractPackageGitHubRepositories)
.mapValue(\.promise)
.flatMapPublisher { packageRepositories in
.flatMapLatestPublisher { packageRepositories in
fetchGithubLicenses(
packageRepositories: packageRepositories,
githubClientID: self.gitClientID,
githubClientSecret: self.gitSecret
).contramapEnvironment(\World.urlSession, \World.githubJsonDecoder)
}
.flatMapPublisher { (packageLicenses: [PackageLicense]) in
.flatMapLatestPublisher { (packageLicenses: [PackageLicense]) in
cocoaPodsModel(packageLicenses: packageLicenses)
.contramapEnvironment(\World.urlSession)
}
.flatMapPublisher { cocoaPods in
.flatMapLatestPublisher { cocoaPods in
saveToPList(cocoaPods: cocoaPods, path: self.outputFile)
.mapValue(\.promise)
.contramapEnvironment(\World.fileSave, \World.cocoaPodsEncoder)
Expand Down

0 comments on commit d0b1cdb

Please sign in to comment.