Skip to content

Commit

Permalink
feat: hidden-graph
Browse files Browse the repository at this point in the history
PublishJob: conditional publishGraph IRI
  • Loading branch information
mchlrch committed Feb 29, 2024
1 parent 13e652a commit d93e2e0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion apis/core/lib/domain/job/create.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,14 @@ export async function createPublishJob({

const metadata = await store.getResource(project.dataset)

const targetGraph = metadata.isHiddenCube ? $rdf.namedNode(organization.publishGraph.value + '/hidden') : organization.publishGraph

const jobPointer = await store.createMember(jobCollection.term, id.job(jobCollection))
const job = Job.createPublish(jobPointer, {
project: projectPointer,
name: 'Publish job',
revision: project.nextRevision,
publishGraph: organization.publishGraph,
publishGraph: targetGraph,
status: metadata?.pointer.out(schema.creativeWorkStatus).term,
publishedTo: metadata?.pointer.out(schema.workExample).term,
})
Expand Down

0 comments on commit d93e2e0

Please sign in to comment.