Skip to content

Commit

Permalink
Make repository inits public
Browse files Browse the repository at this point in the history
  • Loading branch information
rocxteady committed Jun 25, 2024
1 parent 32e0af5 commit 6bc5150
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Sources/WPSwift/Repositories/APIInfoRepository.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import Foundation
import Resting

public struct APIInfoRepository {
public init() {}

public func getAPIInfo(route: String? = nil) async throws -> APIInfo {
let urlString = if let route {
route
Expand Down
2 changes: 2 additions & 0 deletions Sources/WPSwift/Repositories/PostsRepository.swift
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import Foundation
import Resting

public struct PostsRepository {
public init() {}

public func getPostsClient() throws -> WPClient<EmptyModel, [Post]> {
try .init(.init(endpoint: WPEndpoint.Posts.posts.path, parameters: nil))
}
Expand Down

0 comments on commit 6bc5150

Please sign in to comment.