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

Simplify and improve usage of Result pod #579

Merged
merged 1 commit into from
Jul 20, 2018
Merged

Conversation

mathebox
Copy link
Member

No description provided.

@mathebox mathebox requested a review from bjrne July 16, 2018 09:43
@@ -105,11 +105,8 @@ public class SyncEngine {

private func buildCreateRequest(forQuery query: ResourceURLRepresentable,
forResource resource: Pushable) -> Result<URLRequest, XikoloError> {
switch resource.resourceData() {
case let .success(resourceData):
return resource.resourceData().flatMap { resourceData in
Copy link
Contributor

Choose a reason for hiding this comment

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

How does this part work?

Copy link
Member Author

Choose a reason for hiding this comment

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

What du you mean? It's basically the same construct, only shorter.

@mathebox mathebox merged commit 1d847e1 into dev Jul 20, 2018
@mathebox mathebox deleted the better-result-usage branch July 20, 2018 07:35
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