Compare commits
No commits in common. "2106f15d7f3d9b016e76540060710bec86091059" and "df0f8f36f7ca0d562f3f6dee575eb768574ba3d3" have entirely different histories.
2106f15d7f
...
df0f8f36f7
@ -1,7 +1,6 @@
|
|||||||
<?php namespace GermanAirlinesVa\Graphql\Classes;
|
<?php namespace GermanAirlinesVa\Graphql\Classes;
|
||||||
|
|
||||||
use Closure;
|
use Closure;
|
||||||
use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException;
|
|
||||||
|
|
||||||
class Authentication
|
class Authentication
|
||||||
{
|
{
|
||||||
@ -14,11 +13,11 @@ class Authentication
|
|||||||
*/
|
*/
|
||||||
public function handle($request, Closure $next)
|
public function handle($request, Closure $next)
|
||||||
{
|
{
|
||||||
if ($request->header('Gql-Session') === 'SUPER_SECRET_KEY_HEADER') {
|
if ($request->input('gql_session') === 'SUPER_SECRET_TOKEN') {
|
||||||
return "";
|
return "false";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
throw new AccessDeniedHttpException;
|
return "true";
|
||||||
}
|
}
|
||||||
|
|
||||||
return $next($request);
|
return $next($request);
|
||||||
|
|||||||
@ -8,7 +8,7 @@ extend type Query {
|
|||||||
}
|
}
|
||||||
|
|
||||||
extend type Subscription {
|
extend type Subscription {
|
||||||
aircraftAdded: Aircraft @subscription(class: "GermanAirlinesVa\\Fleet\\Classes\\AircraftAdded")
|
aircraftAdded: Aircraft @subscription(class: "GermanAirlinesVa\\Fleet\\Classes\\Aircraft")
|
||||||
}
|
}
|
||||||
|
|
||||||
extend type Mutation {
|
extend type Mutation {
|
||||||
@ -23,7 +23,6 @@ extend type Mutation {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type Aircraft {
|
type Aircraft {
|
||||||
id: ID!
|
|
||||||
aircraft_type_id: ID!
|
aircraft_type_id: ID!
|
||||||
home_airport_id: ID!
|
home_airport_id: ID!
|
||||||
name: String!
|
name: String!
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user