@@ -20,7 +20,7 @@ Let's use a simple example model.
2020 Limiting Field Access
2121---------------------
2222
23- To limit fields in a GraphQL query simply use the ``only_fields `` meta attribute.
23+ To limit fields in a GraphQL query simply use the ``fields `` meta attribute.
2424
2525.. code :: python
2626
@@ -31,10 +31,10 @@ To limit fields in a GraphQL query simply use the ``only_fields`` meta attribute
3131 class PostNode (DjangoObjectType ):
3232 class Meta :
3333 model = Post
34- only_fields = (' title' , ' content' )
34+ fields = (' title' , ' content' )
3535 interfaces = (relay.Node, )
3636
37- conversely you can use ``exclude_fields `` meta attribute.
37+ conversely you can use ``exclude `` meta attribute.
3838
3939.. code :: python
4040
@@ -45,7 +45,7 @@ conversely you can use ``exclude_fields`` meta attribute.
4545 class PostNode (DjangoObjectType ):
4646 class Meta :
4747 model = Post
48- exclude_fields = (' published' , ' owner' )
48+ exclude = (' published' , ' owner' )
4949 interfaces = (relay.Node, )
5050
5151 Queryset Filtering On Lists
@@ -133,7 +133,7 @@ method to your ``DjangoObjectType``.
133133 class PostNode (DjangoObjectType ):
134134 class Meta :
135135 model = Post
136- only_fields = (' title' , ' content' )
136+ fields = (' title' , ' content' )
137137 interfaces = (relay.Node, )
138138
139139 @ classmethod
0 commit comments