-
Notifications
You must be signed in to change notification settings - Fork 32
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
chore: improved documentation #16
Conversation
accesscontroller/default.go
Outdated
@@ -8,6 +9,8 @@ import ( | |||
type Default struct { | |||
} | |||
|
|||
// Checks whether a given identity can append an entry to the log. |
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.
No dot at the end of the sentence (consistency)
accesscontroller/default.go
Outdated
@@ -1,3 +1,4 @@ | |||
// Default access controller for IPFS Log |
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.
Maybe you should make it clear that it's a noop access controller? (in addition to the CanAppend comment)
entry/entry.go
Outdated
@@ -1,18 +1,17 @@ | |||
// Entry structure for IPFS Log and its associated 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.
No dot at the end of the sentence (consistency)
entry/entry.go
Outdated
@@ -298,42 +304,44 @@ func Verify(identity identityprovider.Interface, entry *Entry) error { | |||
return nil | |||
} | |||
|
|||
func ToMultihash(ipfsInstance io.IpfsServices, entry *Entry) (cid.Cid, error) { | |||
if entry == nil { | |||
// Gets the multihash of an Entry. |
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.
No dot at the end of the sentence (consistency)
entry/entry.go
Outdated
|
||
return entryCID, err | ||
} | ||
|
||
func FromMultihash(ipfs io.IpfsServices, hash cid.Cid, provider identityprovider.Interface) (*Entry, error) { | ||
// Creates an Entry from a hash. |
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.
No dot at the end of the sentence (consistency)
return true | ||
} | ||
} | ||
|
||
return false | ||
} | ||
|
||
// Finds an entry's children from an Array of entries. | ||
// Returns entry's children as an Array up to the last know child. |
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.
No dot at the end of the sentence (consistency)
entry/sorting/sorting.go
Outdated
@@ -1,15 +1,19 @@ | |||
package log // import "berty.tech/go-ipfs-log/log" | |||
// Sorting utilities for slices of Entries |
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.
s/utilities/helpers/ ?
errmsg/errmsg.go
Outdated
@@ -1,6 +1,7 @@ | |||
// Error messages used by the Go version of IPFS Log. |
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.
No dot at the end of the sentence (consistency)
identityprovider/identity.go
Outdated
@@ -1,3 +1,4 @@ | |||
// Default identity provider for IPFS Log and OrbitDB. |
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.
No dot at the end of the sentence (consistency)
keystore/keystore.go
Outdated
@@ -1,3 +1,4 @@ | |||
// A local key manager for OrbitDB and IPFS Log. |
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.
No dot at the end of the sentence (consistency)
In addition to the corrections above, golang official linter specifies a format for the comment of exported method / fuction / attributes: https://github.com/golang/lint Running
|
05ac952
to
7ded735
Compare
🎉 This PR is included in version 1.0.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
No description provided.