Skip to content
This repository was archived by the owner on Sep 15, 2025. It is now read-only.

Commit caad5eb

Browse files
author
Emily Laguna
authored
Merge pull request #527 from wordpress-mobile/feature/qrcode-login-networking
Make the QRLoginServiceRemote functions open for testing
2 parents 5c14750 + e7c63cd commit caad5eb

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

WordPressKit/QR Login/QRLoginServiceRemote.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
import Foundation
22
import WordPressShared
33

4-
public class QRLoginServiceRemote: ServiceRemoteWordPressComREST {
4+
open class QRLoginServiceRemote: ServiceRemoteWordPressComREST {
55
/// Validates the incoming QR Login token and retrieves the requesting browser, and location
6-
public func validate(token: String, data: String, success: @escaping (QRLoginValidationResponse) -> Void, failure: @escaping (Error?, QRLoginError?) -> Void) {
6+
open func validate(token: String, data: String, success: @escaping (QRLoginValidationResponse) -> Void, failure: @escaping (Error?, QRLoginError?) -> Void) {
77
let path = self.path(forEndpoint: "auth/qr-code/validate", withVersion: ._2_0)
88
let parameters = [ "token": token, "data": data ] as [String: AnyObject]
99

@@ -29,7 +29,7 @@ public class QRLoginServiceRemote: ServiceRemoteWordPressComREST {
2929
}
3030

3131
/// Authenticates the users browser
32-
public func authenticate(token: String, data: String, success: @escaping(Bool) -> Void, failure: @escaping(Error) -> Void) {
32+
open func authenticate(token: String, data: String, success: @escaping(Bool) -> Void, failure: @escaping(Error) -> Void) {
3333
let path = self.path(forEndpoint: "auth/qr-code/authenticate", withVersion: ._2_0)
3434
let parameters = [ "token": token, "data": data ] as [String: AnyObject]
3535

0 commit comments

Comments
 (0)