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

Add Uphold client #13

Merged
merged 2 commits into from
Nov 6, 2015
Merged

Add Uphold client #13

merged 2 commits into from
Nov 6, 2015

Conversation

diogoguimaraes
Copy link
Contributor

This pull request adds the Uphold client with the ticker service methods.

@diogoguimaraes diogoguimaraes self-assigned this Nov 4, 2015
@diogoguimaraes diogoguimaraes force-pushed the feature/add-uphold-client branch from 17b3c71 to 2801939 Compare November 5, 2015 12:17
@diogoguimaraes diogoguimaraes removed the wip label Nov 5, 2015
@diogoguimaraes
Copy link
Contributor Author

R=@SandroMachado

public override init() {
super.init()

self.bearerToken = nil
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The self.bearerToken = nil is already nil. We don't need to set it to nil.

@diogoguimaraes diogoguimaraes force-pushed the feature/add-uphold-client branch from 2801939 to 0922e07 Compare November 5, 2015 16:58
}

/**
Gets all exchanges rates for all currency pairs.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change to Gets all the exchange rates for all currency pairs..

@diogoguimaraes diogoguimaraes force-pushed the feature/add-uphold-client branch from 0922e07 to af5d9a4 Compare November 5, 2015 17:59
public class Token: BaseModel {

/// The bearer token.
public private(set) var bearerToken: String?
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The getter should also be private.

@diogoguimaraes diogoguimaraes force-pushed the feature/add-uphold-client branch from af5d9a4 to 6187fd7 Compare November 6, 2015 10:22
@diogoguimaraes
Copy link
Contributor Author

Updated @SandroMachado


let client = UpholdClient()
client.token.adapter = MockRestAdapter(body: json)
client.getTickers().then { (rates: [Rate]) -> () in
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a new line.

@diogoguimaraes diogoguimaraes force-pushed the feature/add-uphold-client branch from 6187fd7 to 7810f7a Compare November 6, 2015 12:10
SandroMachado added a commit that referenced this pull request Nov 6, 2015
@SandroMachado SandroMachado merged commit 7c1c1e2 into master Nov 6, 2015
@SandroMachado SandroMachado deleted the feature/add-uphold-client branch November 6, 2015 12:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants