Commits

Luciano Pacheco committed 834c7df

now you can specify fields for result of a method

Comments (0)

Files changed (2)

piston/emitters.py

                         inst = getattr(data, model, None)
 
                         if inst:
+                            if callable(inst):
+                                inst = inst()
                             ret[model] = _any(inst, fields)
 
                     elif maybe_field in met_fields:
 
 setup(
     name = "django-piston",
-    version = "0.2.5.3",
+    version = "0.2.5.4",
     url = 'http://bitbucket.org/jespern/django-piston/wiki/Home',
 	download_url = 'http://bitbucket.org/jespern/django-piston/downloads/',
     license = 'BSD',