Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: bug fixes for Apwrite 1.4.2 #12

Merged
merged 3 commits into from
Sep 7, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

![Swift Package Manager](https://img.shields.io/github/v/release/appwrite/sdk-for-swift.svg?color=green&style=flat-square)
![License](https://img.shields.io/github/license/appwrite/sdk-for-swift.svg?style=flat-square)
![Version](https://img.shields.io/badge/api%20version-1.4.1-blue.svg?style=flat-square)
![Version](https://img.shields.io/badge/api%20version-1.4.2-blue.svg?style=flat-square)
[![Build Status](https://img.shields.io/travis/com/appwrite/sdk-generator?style=flat-square)](https://travis-ci.com/appwrite/sdk-generator)
[![Twitter Account](https://img.shields.io/twitter/follow/appwrite?color=00acee&label=twitter&style=flat-square)](https://twitter.com/appwrite)
[![Discord](https://img.shields.io/discord/564160730845151244?label=discord&style=flat-square)](https://appwrite.io/discord)
Expand Down Expand Up @@ -33,7 +33,7 @@ Add the package to your `Package.swift` dependencies:

```swift
dependencies: [
.package(url: "[email protected]:appwrite/sdk-for-swift.git", from: "3.0.1"),
.package(url: "[email protected]:appwrite/sdk-for-swift.git", from: "4.0.0"),
],
```

Expand Down
2 changes: 1 addition & 1 deletion Sources/Appwrite/Client.swift
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ open class Client {
"x-sdk-name": "Swift",
"x-sdk-platform": "server",
"x-sdk-language": "swift",
"x-sdk-version": "3.0.1",
"x-sdk-version": "4.0.0",
"X-Appwrite-Response-Format": "1.4.0"
]

Expand Down
2 changes: 1 addition & 1 deletion Sources/Appwrite/Services/Functions.swift
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ open class Functions: Service {
open func update(
functionId: String,
name: String,
runtime: String,
runtime: String? = nil,
execute: [String]? = nil,
events: [String]? = nil,
schedule: String? = nil,
Expand Down
4 changes: 2 additions & 2 deletions Sources/Appwrite/Services/Teams.swift
Original file line number Diff line number Diff line change
Expand Up @@ -350,21 +350,21 @@ open class Teams: Service {
///
/// @param String teamId
/// @param [String] roles
/// @param String url
/// @param String email
/// @param String userId
/// @param String phone
/// @param String url
/// @param String name
/// @throws Exception
/// @return array
///
open func createMembership(
teamId: String,
roles: [String],
url: String,
email: String? = nil,
userId: String? = nil,
phone: String? = nil,
url: String? = nil,
name: String? = nil
) async throws -> AppwriteModels.Membership {
let apiPath: String = "/teams/{teamId}/memberships"
Expand Down
2 changes: 1 addition & 1 deletion docs/examples/functions/create.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ let functions = Functions(client)
let function = try await functions.create(
functionId: "[FUNCTION_ID]",
name: "[NAME]",
runtime: "node-14.5"
runtime: "node-18.0"
)

3 changes: 1 addition & 2 deletions docs/examples/functions/update.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ let functions = Functions(client)

let function = try await functions.update(
functionId: "[FUNCTION_ID]",
name: "[NAME]",
runtime: "node-14.5"
name: "[NAME]"
)

3 changes: 1 addition & 2 deletions docs/examples/teams/create-membership.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ let teams = Teams(client)

let membership = try await teams.createMembership(
teamId: "[TEAM_ID]",
roles: [],
url: "https://example.com"
roles: []
)