Skip to content

Commit 3fa8a13

Browse files
authored
Merge pull request #64 from appwrite/dev
release: android
2 parents 2774e02 + 9044167 commit 3fa8a13

File tree

18 files changed

+89
-42
lines changed

18 files changed

+89
-42
lines changed

.github/workflows/autoclose.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
name: Auto-close External Pull Requests
2+
3+
on:
4+
pull_request_target:
5+
types: [opened, reopened]
6+
7+
jobs:
8+
auto_close:
9+
uses: appwrite/.github/.github/workflows/autoclose.yml@main
10+
secrets:
11+
GH_AUTO_CLOSE_PR_TOKEN: ${{ secrets.GH_AUTO_CLOSE_PR_TOKEN }}

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ repositories {
3838
Next, add the dependency to your project's `build.gradle(.kts)` file:
3939

4040
```groovy
41-
implementation("io.appwrite:sdk-for-android:6.0.0")
41+
implementation("io.appwrite:sdk-for-android:6.1.0")
4242
```
4343

4444
### Maven
@@ -49,7 +49,7 @@ Add this to your project's `pom.xml` file:
4949
<dependency>
5050
<groupId>io.appwrite</groupId>
5151
<artifactId>sdk-for-android</artifactId>
52-
<version>6.0.0</version>
52+
<version>6.1.0</version>
5353
</dependency>
5454
</dependencies>
5555
```

example/src/main/java/io/appwrite/android/ui/accounts/AccountsViewModel.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,8 @@ class AccountsViewModel : ViewModel() {
8181
account.createOAuth2Session(
8282
activity,
8383
OAuthProvider.FACEBOOK,
84-
"appwrite-callback-6070749e6acd4://demo.appwrite.io/auth/oauth2/success",
85-
"appwrite-callback-6070749e6acd4://demo.appwrite.io/auth/oauth2/failure"
84+
"appwrite-callback-6070749e6acd4://cloud.appwrite.io/auth/oauth2/success",
85+
"appwrite-callback-6070749e6acd4://cloud.appwrite.io/auth/oauth2/failure"
8686
)
8787
} catch (e: Exception) {
8888
_error.postValue(Event(e))

library/src/main/java/io/appwrite/Client.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ class Client @JvmOverloads constructor(
8686
"x-sdk-name" to "Android",
8787
"x-sdk-platform" to "client",
8888
"x-sdk-language" to "android",
89-
"x-sdk-version" to "6.0.0",
89+
"x-sdk-version" to "6.1.0",
9090
"x-appwrite-response-format" to "1.6.0"
9191
)
9292
config = mutableMapOf()

library/src/main/java/io/appwrite/enums/ImageFormat.kt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ enum class ImageFormat(val value: String) {
1212
@SerializedName("png")
1313
PNG("png"),
1414
@SerializedName("webp")
15-
WEBP("webp");
15+
WEBP("webp"),
16+
@SerializedName("avif")
17+
AVIF("avif");
1618

1719
override fun toString() = value
1820
}

library/src/main/java/io/appwrite/models/Document.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ data class Document<T>(
4141
* Document permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).
4242
*/
4343
@SerializedName("\$permissions")
44-
val permissions: List<Any>,
44+
val permissions: List<String>,
4545

4646
/**
4747
* Additional properties
@@ -66,7 +66,7 @@ data class Document<T>(
6666
databaseId: String,
6767
createdAt: String,
6868
updatedAt: String,
69-
permissions: List<Any>,
69+
permissions: List<String>,
7070
data: Map<String, Any>
7171
) = Document<Map<String, Any>>(
7272
id,
@@ -88,7 +88,7 @@ data class Document<T>(
8888
databaseId = map["\$databaseId"] as String,
8989
createdAt = map["\$createdAt"] as String,
9090
updatedAt = map["\$updatedAt"] as String,
91-
permissions = map["\$permissions"] as List<Any>,
91+
permissions = map["\$permissions"] as List<String>,
9292
data = map.jsonCast(to = nestedType)
9393
)
9494
}

library/src/main/java/io/appwrite/models/Execution.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ data class Execution(
2929
* Execution roles.
3030
*/
3131
@SerializedName("\$permissions")
32-
val permissions: List<Any>,
32+
val permissions: List<String>,
3333

3434
/**
3535
* Function ID.
@@ -139,7 +139,7 @@ data class Execution(
139139
id = map["\$id"] as String,
140140
createdAt = map["\$createdAt"] as String,
141141
updatedAt = map["\$updatedAt"] as String,
142-
permissions = map["\$permissions"] as List<Any>,
142+
permissions = map["\$permissions"] as List<String>,
143143
functionId = map["functionId"] as String,
144144
trigger = map["trigger"] as String,
145145
status = map["status"] as String,

library/src/main/java/io/appwrite/models/File.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ data class File(
3535
* File permissions. [Learn more about permissions](https://appwrite.io/docs/permissions).
3636
*/
3737
@SerializedName("\$permissions")
38-
val permissions: List<Any>,
38+
val permissions: List<String>,
3939

4040
/**
4141
* File name.
@@ -98,7 +98,7 @@ data class File(
9898
bucketId = map["bucketId"] as String,
9999
createdAt = map["\$createdAt"] as String,
100100
updatedAt = map["\$updatedAt"] as String,
101-
permissions = map["\$permissions"] as List<Any>,
101+
permissions = map["\$permissions"] as List<String>,
102102
name = map["name"] as String,
103103
signature = map["signature"] as String,
104104
mimeType = map["mimeType"] as String,

library/src/main/java/io/appwrite/models/Membership.kt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,13 @@ data class Membership(
3232
val userId: String,
3333

3434
/**
35-
* User name.
35+
* User name. Hide this attribute by toggling membership privacy in the Console.
3636
*/
3737
@SerializedName("userName")
3838
val userName: String,
3939

4040
/**
41-
* User email address.
41+
* User email address. Hide this attribute by toggling membership privacy in the Console.
4242
*/
4343
@SerializedName("userEmail")
4444
val userEmail: String,
@@ -74,7 +74,7 @@ data class Membership(
7474
val confirm: Boolean,
7575

7676
/**
77-
* Multi factor authentication status, true if the user has MFA enabled or false otherwise.
77+
* Multi factor authentication status, true if the user has MFA enabled or false otherwise. Hide this attribute by toggling membership privacy in the Console.
7878
*/
7979
@SerializedName("mfa")
8080
val mfa: Boolean,
@@ -83,7 +83,7 @@ data class Membership(
8383
* User list of roles
8484
*/
8585
@SerializedName("roles")
86-
val roles: List<Any>,
86+
val roles: List<String>,
8787

8888
) {
8989
fun toMap(): Map<String, Any> = mapOf(
@@ -120,7 +120,7 @@ data class Membership(
120120
joined = map["joined"] as String,
121121
confirm = map["confirm"] as Boolean,
122122
mfa = map["mfa"] as Boolean,
123-
roles = map["roles"] as List<Any>,
123+
roles = map["roles"] as List<String>,
124124
)
125125
}
126126
}

library/src/main/java/io/appwrite/models/MfaRecoveryCodes.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ data class MfaRecoveryCodes(
1111
* Recovery codes.
1212
*/
1313
@SerializedName("recoveryCodes")
14-
val recoveryCodes: List<Any>,
14+
val recoveryCodes: List<String>,
1515

1616
) {
1717
fun toMap(): Map<String, Any> = mapOf(
@@ -24,7 +24,7 @@ data class MfaRecoveryCodes(
2424
fun from(
2525
map: Map<String, Any>,
2626
) = MfaRecoveryCodes(
27-
recoveryCodes = map["recoveryCodes"] as List<Any>,
27+
recoveryCodes = map["recoveryCodes"] as List<String>,
2828
)
2929
}
3030
}

0 commit comments

Comments
 (0)