Skip to content

Commit 0da6434

Browse files
Merge pull request #16 from appwrite/dev
chore: bug fixes for Apwrite 1.4.2
2 parents 631f3d5 + 438e08c commit 0da6434

File tree

7 files changed

+9
-17
lines changed

7 files changed

+9
-17
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Appwrite Deno SDK
22

33
![License](https://img.shields.io/github/license/appwrite/sdk-for-deno.svg?style=flat-square)
4-
![Version](https://img.shields.io/badge/api%20version-1.4.1-blue.svg?style=flat-square)
4+
![Version](https://img.shields.io/badge/api%20version-1.4.2-blue.svg?style=flat-square)
55
[![Build Status](https://img.shields.io/travis/com/appwrite/sdk-generator?style=flat-square)](https://travis-ci.com/appwrite/sdk-generator)
66
[![Twitter Account](https://img.shields.io/twitter/follow/appwrite?color=00acee&label=twitter&style=flat-square)](https://twitter.com/appwrite)
77
[![Discord](https://img.shields.io/discord/564160730845151244?label=discord&style=flat-square)](https://appwrite.io/discord)

docs/examples/functions/create.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ client
1212
;
1313

1414

15-
let promise = functions.create('[FUNCTION_ID]', '[NAME]', 'node-14.5');
15+
let promise = functions.create('[FUNCTION_ID]', '[NAME]', 'node-18.0');
1616

1717
promise.then(function (response) {
1818
console.log(response);

docs/examples/functions/update.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ client
1212
;
1313

1414

15-
let promise = functions.update('[FUNCTION_ID]', '[NAME]', 'node-14.5');
15+
let promise = functions.update('[FUNCTION_ID]', '[NAME]');
1616

1717
promise.then(function (response) {
1818
console.log(response);

docs/examples/teams/create-membership.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ client
1212
;
1313

1414

15-
let promise = teams.createMembership('[TEAM_ID]', [], 'https://example.com');
15+
let promise = teams.createMembership('[TEAM_ID]', []);
1616

1717
promise.then(function (response) {
1818
console.log(response);

src/client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ export class Client {
1111
endpoint: string = 'https://HOSTNAME/v1';
1212
headers: Payload = {
1313
'content-type': '',
14-
'user-agent' : `AppwriteDenoSDK/8.0.1 (${Deno.build.os}; ${Deno.build.arch})`,
14+
'user-agent' : `AppwriteDenoSDK/9.0.0 (${Deno.build.os}; ${Deno.build.arch})`,
1515
'x-sdk-name': 'Deno',
1616
'x-sdk-platform': 'server',
1717
'x-sdk-language': 'deno',
18-
'x-sdk-version': '8.0.1',
18+
'x-sdk-version': '9.0.0',
1919
'X-Appwrite-Response-Format':'1.4.0',
2020
};
2121

src/services/functions.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ export class Functions extends Service {
218218
* @throws {AppwriteException}
219219
* @returns {Promise}
220220
*/
221-
async update(functionId: string, name: string, runtime: string, execute?: string[], events?: string[], schedule?: string, timeout?: number, enabled?: boolean, logging?: boolean, entrypoint?: string, commands?: string, installationId?: string, providerRepositoryId?: string, providerBranch?: string, providerSilentMode?: boolean, providerRootDirectory?: string): Promise<Models.Function> {
221+
async update(functionId: string, name: string, runtime?: string, execute?: string[], events?: string[], schedule?: string, timeout?: number, enabled?: boolean, logging?: boolean, entrypoint?: string, commands?: string, installationId?: string, providerRepositoryId?: string, providerBranch?: string, providerSilentMode?: boolean, providerRootDirectory?: string): Promise<Models.Function> {
222222
if (typeof functionId === 'undefined') {
223223
throw new AppwriteException('Missing required parameter: "functionId"');
224224
}
@@ -227,10 +227,6 @@ export class Functions extends Service {
227227
throw new AppwriteException('Missing required parameter: "name"');
228228
}
229229

230-
if (typeof runtime === 'undefined') {
231-
throw new AppwriteException('Missing required parameter: "runtime"');
232-
}
233-
234230
const apiPath = '/functions/{functionId}'.replace('{functionId}', functionId);
235231
const payload: Payload = {};
236232

src/services/teams.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -216,15 +216,15 @@ export class Teams extends Service {
216216
*
217217
* @param {string} teamId
218218
* @param {string[]} roles
219-
* @param {string} url
220219
* @param {string} email
221220
* @param {string} userId
222221
* @param {string} phone
222+
* @param {string} url
223223
* @param {string} name
224224
* @throws {AppwriteException}
225225
* @returns {Promise}
226226
*/
227-
async createMembership(teamId: string, roles: string[], url: string, email?: string, userId?: string, phone?: string, name?: string): Promise<Models.Membership> {
227+
async createMembership(teamId: string, roles: string[], email?: string, userId?: string, phone?: string, url?: string, name?: string): Promise<Models.Membership> {
228228
if (typeof teamId === 'undefined') {
229229
throw new AppwriteException('Missing required parameter: "teamId"');
230230
}
@@ -233,10 +233,6 @@ export class Teams extends Service {
233233
throw new AppwriteException('Missing required parameter: "roles"');
234234
}
235235

236-
if (typeof url === 'undefined') {
237-
throw new AppwriteException('Missing required parameter: "url"');
238-
}
239-
240236
const apiPath = '/teams/{teamId}/memberships'.replace('{teamId}', teamId);
241237
const payload: Payload = {};
242238

0 commit comments

Comments
 (0)