Skip to content

Commit

Permalink
[PLA-1899] Expose qr and code for get beam (#87)
Browse files Browse the repository at this point in the history
  • Loading branch information
enjinabner committed Jul 17, 2024
1 parent d7d6963 commit 5be01be
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 4 deletions.
2 changes: 0 additions & 2 deletions src/GraphQL/Types/BeamType.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ public function fields(): array
'code' => [
'type' => GraphQL::type('String!'),
'description' => __('enjin-platform-beam::mutation.claim_beam.args.code'),
'excludeFrom' => ['GetBeam', 'GetBeams'],
],
...$this->getCommonFields(),
'collection' => [
Expand Down Expand Up @@ -92,7 +91,6 @@ public function fields(): array
},
'selectable' => false,
'is_relation' => false,
'excludeFrom' => ['GetBeam', 'GetBeams'],
],
'probabilities' => [
'type' => GraphQL::type('Object'),
Expand Down
2 changes: 1 addition & 1 deletion tests/Feature/GraphQL/Queries/GetBeamTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ public function test_it_hides_code_field_when_unauthenticated()
]);

$response = $this->graphql($this->method, ['code' => $this->beam->code], true);
$this->assertEquals('Cannot query field "code" on type "Beam".', $response['error']);
$this->assertEquals('Cannot query field "code" on type "BeamClaim".', $response['error']);

config([
'enjin-platform.auth' => null,
Expand Down
2 changes: 1 addition & 1 deletion tests/Feature/GraphQL/Queries/GetBeamsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public function test_it_hides_code_field_when_unauthenticated()
]);

$response = $this->graphql($this->method, [], true);
$this->assertEquals('Cannot query field "code" on type "Beam".', $response['error']);
$this->assertEquals('Cannot query field "code" on type "BeamClaim".', $response['error']);

config([
'enjin-platform.auth' => null,
Expand Down

0 comments on commit 5be01be

Please sign in to comment.