-
Notifications
You must be signed in to change notification settings - Fork 2
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
Implement documents.update
#40
Implement documents.update
#40
Conversation
673f739
to
9f48177
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall the code loks good 👍
9f48177
to
e5dc043
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👌
Thanks!
@zadjadr please rebase ;) |
e5dc043
to
752c927
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add the _failed
test also, otherwise just some cosmetic changes
documents.go
Outdated
@@ -78,16 +78,16 @@ type DocumentsCreateClient struct { | |||
params documentsCreateParams | |||
} | |||
|
|||
func newDocumentsCreateClient(sl *sling.Sling, params documentsCreateParams) *DocumentsCreateClient { | |||
func newDocumentsCreateClient(sl *sling.Sling, title string, collectionId CollectionID) *DocumentsCreateClient { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
collectionId -> id; the type shows what the param is representing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed here d87d1c4
documents.go
Outdated
// Update returns a client for updating a single document in the specified collection. | ||
// API reference: https://www.getoutline.com/developers#tag/Documents/paths/~1documents.update/post | ||
func (cl *DocumentsClient) Update(id DocumentID) *DocumentsUpdateClient { | ||
return newDocumentsUpdateClient(cl.sl, id) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please move this above, with other DocumentsClient
methods
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed here a3077af
package_test.go
Outdated
@@ -427,7 +486,7 @@ const exampleCollectionsListResponse_1collection string = ` | |||
} | |||
}` | |||
|
|||
const exampleDocumentsCreateResponse_1documents string = `{ | |||
const exampleDocumentsResponse string = `{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Documents -> Document
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed here 527e858
Fixed here befbbf0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I should have approved this PR, not only commenting 😁
However, LGTM 👌
@zadjadr @rsjethani
I did the requested changes to finnaly get this thing merged.
Please have a look 🚀
(The whole thing will be of course rebased in case you approve 😉 )
Thanks @StefMa, sorry had a pretty packed week! LGTM 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you guys!
Closes #38