mirror of
https://github.com/LukeHagar/website.git
synced 2025-12-10 04:22:18 +00:00
Update team preferences retrieval method
This commit is contained in:
@@ -195,10 +195,10 @@ promise.then(function (response) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Get team preferences
|
// Get team preferences
|
||||||
const promise = teams.get('<TEAM_ID>');
|
const promise = teams.getPrefs('<TEAM_ID>');
|
||||||
|
|
||||||
promise.then(function (team) {
|
promise.then(function (prefs) {
|
||||||
console.log(team.prefs); // Team preferences
|
console.log(prefs); // Team preferences
|
||||||
}, function (error) {
|
}, function (error) {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
});
|
});
|
||||||
@@ -223,10 +223,9 @@ final team = await teams.updatePrefs(
|
|||||||
);
|
);
|
||||||
|
|
||||||
// Get team preferences
|
// Get team preferences
|
||||||
final teamData = await teams.get(
|
final prefs = await teams.getPrefs(
|
||||||
teamId: '<TEAM_ID>'
|
teamId: '<TEAM_ID>'
|
||||||
);
|
);
|
||||||
final prefs = teamData.prefs;
|
|
||||||
```
|
```
|
||||||
```client-apple
|
```client-apple
|
||||||
import Appwrite
|
import Appwrite
|
||||||
@@ -248,10 +247,9 @@ let team = try await teams.updatePrefs(
|
|||||||
)
|
)
|
||||||
|
|
||||||
// Get team preferences
|
// Get team preferences
|
||||||
let teamData = try await teams.get(
|
let prefs = try await teams.getPrefs(
|
||||||
teamId: "<TEAM_ID>"
|
teamId: "<TEAM_ID>"
|
||||||
)
|
)
|
||||||
let prefs = teamData.prefs
|
|
||||||
```
|
```
|
||||||
```client-android-kotlin
|
```client-android-kotlin
|
||||||
import io.appwrite.Client
|
import io.appwrite.Client
|
||||||
@@ -274,10 +272,9 @@ val team = teams.updatePrefs(
|
|||||||
)
|
)
|
||||||
|
|
||||||
// Get team preferences
|
// Get team preferences
|
||||||
val teamData = teams.get(
|
val prefs = teams.getPrefs(
|
||||||
teamId = "<TEAM_ID>"
|
teamId = "<TEAM_ID>"
|
||||||
)
|
)
|
||||||
val prefs = teamData.prefs
|
|
||||||
```
|
```
|
||||||
{% /multicode %}
|
{% /multicode %}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user