public function find($identifier)
    {
        try {
            if (UUIDHelper::isUUID($identifier)) {
                return $this->session->getNodeByIdentifier($identifier);
            }

            return $this->session->getNode($identifier);
        } catch (RepositoryException $e) {
            throw new DocumentNotFoundException(sprintf(
                'Could not find document with ID or path "%s"', $identifier
            ), null, $e);
        }
    }