public function getChangeLogEntry($contentType, $contentId, $id, $cmpOp)
    {
        if (!in_array($cmpOp, ['=', '<', '>'])) {
            throw new \InvalidArgumentException(sprintf('Invalid comparison operator: %s', $cmpOp));
        }

        $query = $this->getChangeLogEntryQuery($contentType, $contentId, $id, $cmpOp);

        /** @var Entity\LogChange $logChange */
        $logChange = $this->findOneWith($query);

        return $logChange;
    }
public function getChangeLogEntry($contentType, $contentId, $id, $cmpOp)
    {
        if (!in_array($cmpOp, ['=', '<', '>'])) {
            throw new \InvalidArgumentException(sprintf('Invalid comparison operator: %s', $cmpOp));
        }

        $query = $this->getChangeLogEntryQuery($contentType, $contentId, $id, $cmpOp);

        /** @var Entity\LogChange $logChange */
        $logChange = $this->findOneWith($query);

        return $logChange;
    }
public function getChangeLogEntry ( $ contentType , $ contentId , $ id , $ cmpOp ) { if ( ! in_array ( $ cmpOp , [ '=' , '<' , '>' ] ) ) { throw new \ InvalidArgumentException ( sprintf ( 'Invalid comparison operator: %s' , $ cmpOp ) ) ; } $ query = $ this -> getChangeLogEntryQuery ( $ contentType , $ contentId , $ id , $ cmpOp ) ; /** @var Entity\LogChange $logChange */ $ logChange = $ this -> findOneWith ( $ query ) ; return $ logChange ; }
Get one changelog entry from the database.

@param mixed  $contentType ContentType slug
@param int    $contentId   Content record ID
@param int    $id          The content change log ID
@param string $cmpOp       one of '=', '<', '>'; this parameter is used
to select either the ID itself, or the subsequent
or preceding entry

@throws \InvalidArgumentException

@return \Bolt\Storage\Entity\LogChange|false
Get one changelog entry from the database .