jenkins-bot has submitted this change and it was merged. (
https://gerrit.wikimedia.org/r/392448 )
Change subject: Fix NewStatement generating invalid statement GUIDs
......................................................................
Fix NewStatement generating invalid statement GUIDs
Change-Id: I731312a810bb9d97dd3cf78fb8a7125aecb82340
---
M repo/tests/phpunit/includes/NewStatement.php
1 file changed, 6 insertions(+), 6 deletions(-)
Approvals:
Addshore: Looks good to me, approved
jenkins-bot: Verified
diff --git a/repo/tests/phpunit/includes/NewStatement.php
b/repo/tests/phpunit/includes/NewStatement.php
index 1d5ab56..287a9cc 100644
--- a/repo/tests/phpunit/includes/NewStatement.php
+++ b/repo/tests/phpunit/includes/NewStatement.php
@@ -204,12 +204,12 @@
$result = new Statement( $snack );
$result->setRank( $this->rank );
- if ( $this->guid ) {
- if ( $this->guid === self::GENERATE_GUID ) {
- $result->setGuid( $this->generateUuidV4() );
- } else {
- $result->setGuid( $this->guid );
- }
+ if ( $this->guid === self::GENERATE_GUID ) {
+ $result->setGuid(
+ $this->propertyId->getSerialization() . '$' .
$this->generateUuidV4()
+ );
+ } elseif ( $this->guid ) {
+ $result->setGuid( $this->guid );
}
foreach ( $this->qualifiers as $qualifier ) {
--
To view, visit https://gerrit.wikimedia.org/r/392448
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I731312a810bb9d97dd3cf78fb8a7125aecb82340
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Wikibase
Gerrit-Branch: master
Gerrit-Owner: Thiemo Mättig (WMDE) <[email protected]>
Gerrit-Reviewer: Addshore <[email protected]>
Gerrit-Reviewer: Jonas Kress (WMDE) <[email protected]>
Gerrit-Reviewer: Ladsgroup <[email protected]>
Gerrit-Reviewer: Thiemo Mättig (WMDE) <[email protected]>
Gerrit-Reviewer: WMDE-leszek <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits