From 81226965c78d2e394603fcdd055284787d800472 Mon Sep 17 00:00:00 2001 From: Maksim Karelov Date: Sun, 5 Apr 2015 13:11:31 +0300 Subject: [PATCH] Fixed callback as optional parameters --- jquery.jsonrpcclient/jquery.jsonrpcclient.d.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jquery.jsonrpcclient/jquery.jsonrpcclient.d.ts b/jquery.jsonrpcclient/jquery.jsonrpcclient.d.ts index de008dc09..2965f26f1 100644 --- a/jquery.jsonrpcclient/jquery.jsonrpcclient.d.ts +++ b/jquery.jsonrpcclient/jquery.jsonrpcclient.d.ts @@ -28,7 +28,7 @@ interface JsonRpcClient { * * @return {object} Returns the deferred object that $.ajax returns or {null} for websockets */ - call(method: string, params: Object | Array, successCb: (result: any) => void, errorCb: (result: any) => void): JQueryDeferred; + call(method: string, params: Object | Array, successCb?: (result: any) => void, errorCb?: (result: any) => void): JQueryDeferred; /** * Notify sends a command to the server that won't need a response. In http, there is probably @@ -62,7 +62,7 @@ interface JsonRpcClient { * Note, that batch calls should always get an overall success, and the * only error */ - batch(callback: (batch: JsonRpcClient) => void, allDoneCb: (result: any) => void, errorCb: (error: any) => void): void; + batch(callback: (batch: JsonRpcClient) => void, allDoneCb?: (result: any) => void, errorCb?: (error: any) => void): void; } interface JsonRpcClientFactory {