From 7206862bae56c83abf5924fe065d123a1dbc98ad Mon Sep 17 00:00:00 2001 From: Florian M Date: Wed, 27 Nov 2024 20:54:28 +0100 Subject: [PATCH] Fix accessing public datasets (#8242) --- app/controllers/DatasetController.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/DatasetController.scala b/app/controllers/DatasetController.scala index 59c19b6c60..f7c600459d 100755 --- a/app/controllers/DatasetController.scala +++ b/app/controllers/DatasetController.scala @@ -264,7 +264,7 @@ class DatasetController @Inject()(userService: UserService, for { datasetIdValidated <- ObjectId.fromString(datasetId) dataset <- datasetDAO.findOne(datasetIdValidated)(ctx) ?~> notFoundMessage(datasetId) ~> NOT_FOUND - organization <- organizationDAO.findOne(dataset._organization) ~> NOT_FOUND + organization <- organizationDAO.findOne(dataset._organization)(GlobalAccessContext) ~> NOT_FOUND _ <- Fox.runOptional(request.identity)(user => datasetLastUsedTimesDAO.updateForDatasetAndUser(dataset._id, user._id)) // Access checked above via dataset. In case of shared dataset/annotation, show datastore even if not otherwise accessible