/** * Filter the query by a related \Thelia\Model\ContentVersion object * * @param \Thelia\Model\ContentVersion|ObjectCollection $contentVersion the related object to use as filter * @param string $comparison Operator to use for the column comparison, defaults to Criteria::EQUAL * * @return ChildContentQuery The current query, for fluid interface */ public function filterByContentVersion($contentVersion, $comparison = null) { if ($contentVersion instanceof \Thelia\Model\ContentVersion) { return $this->addUsingAlias(ContentTableMap::ID, $contentVersion->getId(), $comparison); } elseif ($contentVersion instanceof ObjectCollection) { return $this->useContentVersionQuery()->filterByPrimaryKeys($contentVersion->getPrimaryKeys())->endUse(); } else { throw new PropelException('filterByContentVersion() only accepts arguments of type \\Thelia\\Model\\ContentVersion or Collection'); } }