/** * Metoda pro kontrolu oprávněnosti přistupovat ke zvolenému mineru * @param Miner|int|null $miner * @throws UnauthorizedRequestException */ protected function checkMinerAccess($miner) { if (!$this->minersFacade->checkMinerAccess($miner, $this->getCurrentUser())) { throw new UnauthorizedRequestException('You are not authorized to use the selected miner!'); } }