Merge "Log the reason why revision->getContent() returns null"
[lhc/web/wiklou.git] / includes / libs / xmp / XMPValidate.php
index 31eaa3b..7aec28e 100644 (file)
@@ -23,6 +23,7 @@
 
 use Psr\Log\LoggerInterface;
 use Psr\Log\LoggerAwareInterface;
+use Wikimedia\Timestamp\ConvertibleTimestamp;
 
 /**
  * This contains some static methods for
@@ -261,14 +262,12 @@ class XMPValidate implements LoggerAwareInterface {
                        return;
                }
                $res = [];
-               // @codingStandardsIgnoreStart Long line that cannot be broken
                if ( !preg_match(
                        /* ahh! scary regex... */
+                       // phpcs:ignore Generic.Files.LineLength
                        '/^([0-3]\d{3})(?:-([01]\d)(?:-([0-3]\d)(?:T([0-2]\d):([0-6]\d)(?::([0-6]\d)(?:\.\d+)?)?([-+]\d{2}:\d{2}|Z)?)?)?)?$/D',
                        $val, $res )
                ) {
-                       // @codingStandardsIgnoreEnd
-
                        $this->logger->info( __METHOD__ . " Expected date but got $val" );
                        $val = null;
                } else {