Skip to content

Commit 6c5b054

Browse files
edmargomesfubhy
authored andcommitted
Change parameter names in LoadEntityByUuid producer. (#849)
1 parent b42e147 commit 6c5b054

3 files changed

Lines changed: 8 additions & 8 deletions

File tree

src/Plugin/GraphQL/DataProducer/Entity/EntityLoadByUuid.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,18 +21,18 @@
2121
* label = @Translation("Entity")
2222
* ),
2323
* consumes = {
24-
* "entity_type" = @ContextDefinition("string",
24+
* "type" = @ContextDefinition("string",
2525
* label = @Translation("Entity type")
2626
* ),
27-
* "entity_uuid" = @ContextDefinition("string",
27+
* "uuid" = @ContextDefinition("string",
2828
* label = @Translation("Unique identifier")
2929
* ),
30-
* "entity_language" = @ContextDefinition("string",
30+
* "language" = @ContextDefinition("string",
3131
* label = @Translation("Entity languages(s)"),
3232
* multiple = TRUE,
3333
* required = FALSE
3434
* ),
35-
* "entity_bundle" = @ContextDefinition("string",
35+
* "bundle" = @ContextDefinition("string",
3636
* label = @Translation("Entity bundle(s)"),
3737
* multiple = TRUE,
3838
* required = FALSE

tests/src/Kernel/DataProducer/EntityTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -317,8 +317,8 @@ public function testResolveEntityLoad() {
317317
*/
318318
public function testResolveEntityLoadByUuid() {
319319
$result = $this->executeDataProducer('entity_load_by_uuid', [
320-
'entity_type' => $this->node->getEntityTypeId(),
321-
'entity_uuid' => $this->node->uuid(),
320+
'type' => $this->node->getEntityTypeId(),
321+
'uuid' => $this->node->uuid(),
322322
]);
323323

324324
$this->assertEquals($this->node->id(), $result->id());

tests/src/Kernel/EntityUuidBufferTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,8 @@ public function testEntityUuidBuffer() {
7070

7171
$this->mockResolver('Query', 'node',
7272
$this->builder->produce('entity_load_by_uuid')
73-
->map('entity_type', $this->builder->fromValue('node'))
74-
->map('entity_uuid', $this->builder->fromArgument('uuid'))
73+
->map('type', $this->builder->fromValue('node'))
74+
->map('uuid', $this->builder->fromArgument('uuid'))
7575
);
7676

7777
$this->mockResolver('Node', 'title',

0 commit comments

Comments
 (0)