Reference scope by same name as serialization scope

By default, the serialization scope uses current_user, and you can
now reference the scope as "current_user" in the serializer. If you
override the scope using "serialization_scope" in your controller,
it will use that method name instead.
This commit is contained in:
beerlington
2013-03-16 17:58:17 -04:00
parent 41a389a900
commit 4a13f86961
6 changed files with 106 additions and 11 deletions

View File

@@ -1,5 +1,9 @@
# unreleased
* Add an alias for `scope` method to be the name of the context. By default
this is `current_user`. The name is automatically set when using
`serialization_scope` in the controller.
# VERSION 0.7