Skip to content

Conversation

@jobnte
Copy link

@jobnte jobnte commented Oct 3, 2019

No description provided.

jobnte added 2 commits October 3, 2019 10:20
Update dependencies in order to use Swift 5
Fix objective function errors
Update Alamofire version to 5.0.0-rc.2
@phrohdoh
Copy link
Collaborator

phrohdoh commented Oct 3, 2019

Hey, welcome to the project and thanks for the contribution!! 🎉

Would it be possible for ApiResult<T> to become a type alias for Result<T, ApiServiceError> so we don't have to duplicate the error type in multiple places?

@jobnte
Copy link
Author

jobnte commented Oct 3, 2019

Hey, welcome to the project and thanks for the contribution!! 🎉

Would it be possible for ApiResult<T> to become a type alias for Result<T, ApiServiceError> so we don't have to duplicate the error type in multiple places?

Great suggestion !. I updated my code

case failureRequestError
}

typealias ApiResult<T> = Result<T, Error>
Copy link
Collaborator

Choose a reason for hiding this comment

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

This should be Result<T, ApiServiceError> since all of ApiResult's uses have en error type of ApiServiceError.

Copy link
Author

Choose a reason for hiding this comment

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

My bad. I just fixed it

@phrohdoh
Copy link
Collaborator

phrohdoh commented Oct 4, 2019

@laurrenreed Any chance you or someone else could take a look at merging this? :)

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