From 3d765c8f812d6863a310df186665f4086bb6ee9d Mon Sep 17 00:00:00 2001 From: Jasper Siegmund Date: Wed, 22 Jun 2016 08:39:33 +0200 Subject: [PATCH] Changed some of the parameters to optional As per comment / instructions, I've changed the parameters to optionals. --- .../AzureMobileServicesClient.d.ts | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/azure-mobile-services-client/AzureMobileServicesClient.d.ts b/azure-mobile-services-client/AzureMobileServicesClient.d.ts index d401b4d1bc..707e7222d8 100644 --- a/azure-mobile-services-client/AzureMobileServicesClient.d.ts +++ b/azure-mobile-services-client/AzureMobileServicesClient.d.ts @@ -9,8 +9,7 @@ declare namespace Microsoft.WindowsAzure { // MobileServiceClient object based on Microsoft Azure documentation: http://msdn.microsoft.com/en-us/library/windowsazure/jj554219.aspx interface MobileServiceClient { - new (applicationUrl: string): MobileServiceClient; - new (applicationUrl: string, applicationKey: string): MobileServiceClient; + new (applicationUrl: string, applicationKey?: string): MobileServiceClient; applicationUrl: string; applicationKey: string; currentUser: User; @@ -34,7 +33,7 @@ declare namespace Microsoft.WindowsAzure { * headers: HTTP request headers, specified as an object. * @param callback Optional callback accepting (error, results) parameters. */ - invokeApi(apiName: string, options: InvokeApiOptions, callback: (error: any, results: any) => void): asyncPromise; + invokeApi(apiName: string, options?: InvokeApiOptions, callback?: (error: any, results: any) => void): asyncPromise; } interface Push @@ -48,14 +47,14 @@ declare namespace Microsoft.WindowsAzure { * @param secondaryTiles An object containing template definitions to be used with secondary tiles when using WNS. * @param callback Optional callback accepting (error, results) parameters. */ - register(platform: string, pushChannel: string, templates: any, secondaryTiles: any, callback: (error: any, results: any) => void): void; + register(platform: string, pushChannel: string, templates?: any, secondaryTiles?: any, callback?: (error: any, results: any) => void): void; /** * Invokes the specified custom api and returns a response object. * * @param pushChannel The push channel identifier or URI. * @param callback Optional callback accepting (error, results) parameters. */ - unregister(pushChannel: string, callback: (error: any, results: any) => void): void; + unregister(pushChannel: string, callback?: (error: any, results: any) => void): void; } interface InvokeApiOptions @@ -141,4 +140,4 @@ declare module "azure-mobile-apps-client" { export = WindowsAzure; } -declare var WindowsAzure: Microsoft.WindowsAzure.WindowsAzureStatic; \ No newline at end of file +declare var WindowsAzure: Microsoft.WindowsAzure.WindowsAzureStatic;