Thiemo Mättig (WMDE) has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/257592

Change subject: Fix format name strings in parsers
......................................................................

Fix format name strings in parsers

As far as I can tell this is not a breaking change. These constants
are not used anywhere except for exception messages. There was quite
some confusion about these constants when we introduced new parsers and
renamed existing parser classes. With this patch I'm applying the most
simple naming scheme: identical to the relevant part of the class name,
lowercase, separated with dashes.

Please merge https://github.com/DataValues/Time/pull/97 along with this.

Change-Id: Id4bfc429a5d22025f9fc0a29d7c30c7f7ffc10a9
---
M repo/includes/Parsers/EntityIdValueParser.php
M repo/includes/Parsers/MonolingualTextParser.php
M repo/includes/Parsers/YearMonthTimeParser.php
3 files changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Wikibase 
refs/changes/92/257592/1

diff --git a/repo/includes/Parsers/EntityIdValueParser.php 
b/repo/includes/Parsers/EntityIdValueParser.php
index bc7e04c..de9a742 100644
--- a/repo/includes/Parsers/EntityIdValueParser.php
+++ b/repo/includes/Parsers/EntityIdValueParser.php
@@ -20,7 +20,7 @@
  */
 class EntityIdValueParser extends StringValueParser {
 
-       const FORMAT_NAME = 'entity-id';
+       const FORMAT_NAME = 'entity-id-value';
 
        /**
         * @var EntityIdParser
diff --git a/repo/includes/Parsers/MonolingualTextParser.php 
b/repo/includes/Parsers/MonolingualTextParser.php
index 1721f2e..8d77208 100644
--- a/repo/includes/Parsers/MonolingualTextParser.php
+++ b/repo/includes/Parsers/MonolingualTextParser.php
@@ -18,7 +18,7 @@
  */
 class MonolingualTextParser extends StringValueParser {
 
-       const FORMAT_NAME = 'monolingualtext';
+       const FORMAT_NAME = 'monolingual-text';
 
        /**
         * @see StringValueParser::stringParse
diff --git a/repo/includes/Parsers/YearMonthTimeParser.php 
b/repo/includes/Parsers/YearMonthTimeParser.php
index dfe4325..fb63e78 100644
--- a/repo/includes/Parsers/YearMonthTimeParser.php
+++ b/repo/includes/Parsers/YearMonthTimeParser.php
@@ -23,7 +23,7 @@
  */
 class YearMonthTimeParser extends StringValueParser {
 
-       const FORMAT_NAME = 'yearmonth';
+       const FORMAT_NAME = 'year-month';
 
        /**
         * @var int[]

-- 
To view, visit https://gerrit.wikimedia.org/r/257592
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id4bfc429a5d22025f9fc0a29d7c30c7f7ffc10a9
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Thiemo Mättig (WMDE) <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to