diff --git a/lib/client.js b/lib/client.js index 1b8b837..4d32ee6 100644 --- a/lib/client.js +++ b/lib/client.js @@ -10,7 +10,7 @@ class Client { this.endpoint = 'https://HOSTNAME/v1'; this.headers = { 'content-type': '', - 'x-sdk-version': 'appwrite:nodejs:7.0.0', + 'x-sdk-version': 'appwrite:nodejs:7.0.1', 'X-Appwrite-Response-Format' : '0.15.0', }; this.selfSigned = false; diff --git a/lib/services/functions.js b/lib/services/functions.js index b537abe..075e2de 100644 --- a/lib/services/functions.js +++ b/lib/services/functions.js @@ -393,7 +393,7 @@ class Functions extends Service { } const stream = Stream.Readable.from(currentChunk); - payload['code'] = { type: 'file', file: stream, filename: file.filename }; + payload['code'] = { type: 'file', file: stream, filename: code.filename }; response = await selfClient.call('post', path, headers, payload); diff --git a/package.json b/package.json index de8132c..682bef4 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "node-appwrite", "homepage": "https://appwrite.io/support", "description": "Appwrite is an open-source self-hosted backend server that abstract and simplify complex and repetitive development tasks behind a very simple REST API", - "version": "7.0.0", + "version": "7.0.1", "license": "BSD-3-Clause", "main": "./index.js", "types": "./index.d.ts",