mirror of
https://github.com/wassname/talk.git
synced 2026-08-03 13:20:59 +08:00
fix: fix graphiql
This commit is contained in:
@@ -28,7 +28,7 @@ export const graphqlMiddleware = (
|
||||
// Generate the validation rules.
|
||||
const validationRules: Array<(context: ValidationContext) => any> = [];
|
||||
|
||||
if (config.get("env") === "production") {
|
||||
if (config.get("env") === "production" && !config.get("enable_graphiql")) {
|
||||
// Disable introspection in production.
|
||||
validationRules.push(NoIntrospection);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user