Skip to content

Commit

Permalink
add omit guard exception
Browse files Browse the repository at this point in the history
  • Loading branch information
solverat committed Jul 14, 2019
1 parent 8da4f7a commit 34f316e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/DsWebCrawlerBundle/Guard/DefaultDataResourceGuard.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace DsWebCrawlerBundle\Guard;

use DsWebCrawlerBundle\DsWebCrawlerBundle;
use DynamicSearchBundle\Exception\OmitGuardException;
use DynamicSearchBundle\Guard\ContextGuardInterface;
use DynamicSearchBundle\Normalizer\Resource\ResourceMetaInterface;

Expand All @@ -14,7 +15,7 @@ class DefaultDataResourceGuard implements ContextGuardInterface
public function isValidateDataResource(string $contextName, string $dataProviderName, array $dataProviderOptions, ResourceMetaInterface $resourceMeta, $resource)
{
if ($dataProviderName !== DsWebCrawlerBundle::PROVIDER_NAME) {
return true;
throw new OmitGuardException();
}

return true;
Expand Down

0 comments on commit 34f316e

Please sign in to comment.