Compare commits

..

No commits in common. "2106f15d7f3d9b016e76540060710bec86091059" and "df0f8f36f7ca0d562f3f6dee575eb768574ba3d3" have entirely different histories.

2 changed files with 4 additions and 6 deletions

View File

@ -1,7 +1,6 @@
<?php namespace GermanAirlinesVa\Graphql\Classes;
use Closure;
use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException;
class Authentication
{
@ -14,11 +13,11 @@ class Authentication
*/
public function handle($request, Closure $next)
{
if ($request->header('Gql-Session') === 'SUPER_SECRET_KEY_HEADER') {
return "";
if ($request->input('gql_session') === 'SUPER_SECRET_TOKEN') {
return "false";
}
else {
throw new AccessDeniedHttpException;
return "true";
}
return $next($request);

View File

@ -8,7 +8,7 @@ extend type Query {
}
extend type Subscription {
aircraftAdded: Aircraft @subscription(class: "GermanAirlinesVa\\Fleet\\Classes\\AircraftAdded")
aircraftAdded: Aircraft @subscription(class: "GermanAirlinesVa\\Fleet\\Classes\\Aircraft")
}
extend type Mutation {
@ -23,7 +23,6 @@ extend type Mutation {
}
type Aircraft {
id: ID!
aircraft_type_id: ID!
home_airport_id: ID!
name: String!