We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 374f361 commit f4ed2afCopy full SHA for f4ed2af
src/SupabaseClient.ts
@@ -95,10 +95,16 @@ export default class SupabaseClient {
95
*
96
* @param fn The function name to call.
97
* @param params The parameters to pass to the function call.
98
+ * @param count Count algorithm to use to count rows in a table.
99
+ *
100
*/
- rpc<T = any>(fn: string, params?: object) {
101
+ rpc<T = any>(
102
+ fn: string,
103
+ params?: object,
104
+ { count = null }: { count?: null | 'exact' | 'planned' | 'estimated' } = {}
105
+ ) {
106
const rest = this._initPostgRESTClient()
- return rest.rpc<T>(fn, params)
107
+ return rest.rpc<T>(fn, params, { count })
108
}
109
110
/**
0 commit comments