Invoke Custom Methods odata type error

Hi,
Working on a custom method and tried using the SingleResult in a method from code I cut and pasted
from controllers. It didn't work and gives me some error message about not being odata?

I attached the file with the simple examples I was trying. The one that failed is called GetSupaliCustodianByASPNetUserId. What I'm trying to do is return a single record from a database table based on the userId which is the guid you see in the code.
Can you give me some tips on how to do it?
ServerMethodsController.zip (1022 Bytes)

Indeed you can use SingleResult only in OData controllers. This is an implementation detail of the Microsoft OData stack. You can return your result as JSON as shown in our documentation.