acl->checkScope(Import::ENTITY_TYPE)) { throw new Forbidden(); } $id = $request->getRouteParam('id'); if (!$id) { throw new BadRequest(); } $data = $request->getParsedBody(); $entityType = $data->entityType ?? null; $entityId = $data->entityId ?? null; if (!$entityType || !$entityId) { throw new BadRequest("No `entityType` or `entityId`."); } $this->service->unmarkAsDuplicate($id, $entityType, $entityId); return ResponseComposer::json(true); } }