Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Enable graphiql only when DEBUG=True

Marcin Gębalace02f48ea85b
diff --git a/saleor/urls.py b/saleor/urls.py
index ab636f98d9..fb1dad36bb 100644
--- a/saleor/urls.py
+++ b/saleor/urls.py
@@ -27,7 +27,7 @@ urlpatterns = [
url(r'^cart/', include(cart_urls, namespace='cart')),
url(r'^checkout/', include(checkout_urls, namespace='checkout')),
url(r'^dashboard/', include(dashboard_urls, namespace='dashboard')),
- url(r'^graphql', GraphQLView.as_view(graphiql=True)),
+ url(r'^graphql', GraphQLView.as_view(graphiql=settings.DEBUG)),
url(r'^order/', include(order_urls, namespace='order')),
url(r'^products/', include(product_urls, namespace='product')),
url(r'^profile/', include(userprofile_urls, namespace='profile')),