Skip to content

Commit cfc9baa

Browse files
fix: database class getters
1 parent d572ce0 commit cfc9baa

File tree

5 files changed

+21
-27
lines changed

5 files changed

+21
-27
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ import { Client, Account } from "appwrite";
3333
To install with a CDN (content delivery network) add the following scripts to the bottom of your <body> tag, but before you use any Appwrite services:
3434

3535
```html
36-
<script src="https://cdn.jsdelivr.net/npm/[email protected].0"></script>
36+
<script src="https://cdn.jsdelivr.net/npm/[email protected].1"></script>
3737
```
3838

3939

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "appwrite",
33
"homepage": "https://appwrite.io/support",
44
"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",
5-
"version": "9.0.0",
5+
"version": "9.0.1",
66
"license": "BSD-3-Clause",
77
"main": "dist/cjs/sdk.js",
88
"exports": {

src/client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ class Client {
9999
locale: '',
100100
};
101101
headers: Headers = {
102-
'x-sdk-version': 'appwrite:web:9.0.0',
102+
'x-sdk-version': 'appwrite:web:9.0.1',
103103
'X-Appwrite-Response-Format': '0.15.0',
104104
};
105105

src/services/account.ts

Lines changed: 17 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -240,10 +240,11 @@ export class Account extends Service {
240240
/**
241241
* Update Account Phone
242242
*
243-
* Update currently logged in user account phone number. After changing phone
244-
* number, the user confirmation status will get reset. A new confirmation SMS
245-
* is not sent automatically however you can use the phone confirmation
246-
* endpoint again to send the confirmation SMS.
243+
* Update the currently logged in user's phone number. After updating the
244+
* phone number, the phone verification status will be reset. A confirmation
245+
* SMS is not sent automatically, however you can use the [POST
246+
* /account/verification/phone](/docs/client/account#accountCreatePhoneVerification)
247+
* endpoint to send a confirmation SMS.
247248
*
248249
* @param {string} number
249250
* @param {string} password
@@ -682,8 +683,8 @@ export class Account extends Service {
682683
/**
683684
* Create Phone session
684685
*
685-
* Sends the user a SMS with a secret key for creating a session. Use the
686-
* returned user ID and the secret to submit a request to the [PUT
686+
* Sends the user an SMS with a secret key for creating a session. Use the
687+
* returned user ID and secret and submit a request to the [PUT
687688
* /account/sessions/phone](/docs/client/account#accountUpdatePhoneSession)
688689
* endpoint to complete the login process. The secret sent to the user's phone
689690
* is valid for 15 minutes.
@@ -722,17 +723,11 @@ export class Account extends Service {
722723
/**
723724
* Create Phone session (confirmation)
724725
*
725-
* Use this endpoint to complete creating the session with the Magic URL. Both
726-
* the **userId** and **secret** arguments will be passed as query parameters
727-
* to the redirect URL you have provided when sending your request to the
728-
* [POST
729-
* /account/sessions/magic-url](/docs/client/account#accountCreateMagicURLSession)
730-
* endpoint.
731-
*
732-
* Please note that in order to avoid a [Redirect
733-
* Attack](https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.md)
734-
* the only valid redirect URLs are the ones from domains you have set when
735-
* adding your platforms in the console interface.
726+
* Use this endpoint to complete creating a session with SMS. Use the
727+
* **userId** from the
728+
* [createPhoneSession](/docs/client/account#accountCreatePhoneSession)
729+
* endpoint and the **secret** received via SMS to successfully update and
730+
* confirm the phone session.
736731
*
737732
* @param {string} userId
738733
* @param {string} secret
@@ -943,13 +938,12 @@ export class Account extends Service {
943938
/**
944939
* Create Phone Verification
945940
*
946-
* Use this endpoint to send a verification message to your user's phone
947-
* number to confirm they are the valid owners of that address. The provided
948-
* secret should allow you to complete the verification process by verifying
949-
* both the **userId** and **secret** parameters. Learn more about how to
950-
* [complete the verification
941+
* Use this endpoint to send a verification SMS to the currently logged in
942+
* user. This endpoint is meant for use after updating a user's phone number
943+
* using the [accountUpdatePhone](/docs/client/account#accountUpdatePhone)
944+
* endpoint. Learn more about how to [complete the verification
951945
* process](/docs/client/account#accountUpdatePhoneVerification). The
952-
* verification link sent to the user's phone number is valid for 15 minutes.
946+
* verification code sent to the user's phone number is valid for 15 minutes.
953947
*
954948
* @throws {AppwriteException}
955949
* @returns {Promise}

src/services/databases.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export class Databases extends Service {
1313
{
1414
this.databaseId = databaseId;
1515
}
16-
public getDatabaseId(databaseId: string): string
16+
public getDatabaseId(): string
1717
{
1818
return this.databaseId;
1919
}

0 commit comments

Comments
 (0)