Skip to content

Commit 3f1fe29

Browse files
fix: security
1 parent 99bba71 commit 3f1fe29

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

gen.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
typescript:
2+
packagename: "@speakeasy-api/speakeasy-client-sdk-typescript"
3+
version: 0.0.1
4+
author: Speakeasy

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
2-
"name": "",
3-
"version": "",
4-
"author": "",
2+
"name": "@speakeasy-api/speakeasy-client-sdk-typescript",
3+
"version": "0.0.1",
4+
"author": "Speakeasy",
55
"scripts": {
66
"lint:fix": "tsc --noemit && eslint \"./src\" --ext .ts,.tsx --fix"
77
},

src/sdk/sdk.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ export function WithServerURL(serverURL: string, params?: Map<string, string>):
2525
}
2626
}
2727
export function WithSecurity(serverURL: string, security: Security): Function {
28+
if (!(security instanceof utils.SpeakeasyBase)) {
29+
security = new Security(security);
30+
}
2831
return (sdk: SDK) => {
2932
sdk.serverURL = serverURL;
3033
sdk.securityClient = CreateSecurityClient(serverURL, security);

0 commit comments

Comments
 (0)