oops, wrong condition
authorJean-Guilhem Rouel <jean-gui@w3.org>
Tue, 05 Aug 2014 14:26:30 +0200
changeset 330 b5b5d02f9b01
parent 329 b1eee6b311f2
child 331 08826af0ef87
oops, wrong condition
src/Org/W3/Cg/Pub/SpecBundle/Entity/SpecRev.php
--- a/src/Org/W3/Cg/Pub/SpecBundle/Entity/SpecRev.php	Tue Aug 05 14:12:10 2014 +0200
+++ b/src/Org/W3/Cg/Pub/SpecBundle/Entity/SpecRev.php	Tue Aug 05 14:26:30 2014 +0200
@@ -288,7 +288,7 @@
 
     public function isURLValid(ExecutionContext $context)
     {
-        if ($this->getFinal() && preg_match('|^https?://([^/]+\.)?w3.org/|', $this->getUri()) === 1) {
+        if ($this->getFinal() && !preg_match('|^https?://([^/]+\.)?w3.org/|', $this->getUri())) {
             $propertyPath = $context->getPropertyPath(). '.uri';
             $context->setPropertyPath($propertyPath);
             $context->addViolation('A final report must be hosted on w3.org');