-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Description
Currently we have the OCSResponse in OCP https://github.com/nextcloud/server/blob/master/lib/public/AppFramework/Http/OCSResponse.php
However I question the use of this. Since people writing OCS code will use the OCSController which takes a DataResponse: https://github.com/nextcloud/server/blob/master/lib/public/AppFramework/Http/OCSResponse.php
On top of that the first OCSResponse parameter is the format string https://github.com/nextcloud/server/blob/master/lib/public/AppFramework/Http/OCSResponse.php#L57 which is weird since it is the job of the AppFramework/Controller to set this properly. When I'm writing my endpoint I don't want to care. I just want to return data.
So what I propose:
- Deprecate OCSResponse in OCP
- Create an internal OCSResponse type that does the correct magic
Good/bad idea? Comments? @BernhardPosselt @LukasReschke @nickvergessen @MorrisJobke