aboutsummaryrefslogtreecommitdiff
path: root/vendor/github.com/google/go-github/github/git_trees.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/google/go-github/github/git_trees.go')
-rw-r--r--vendor/github.com/google/go-github/github/git_trees.go12
1 files changed, 6 insertions, 6 deletions
diff --git a/vendor/github.com/google/go-github/github/git_trees.go b/vendor/github.com/google/go-github/github/git_trees.go
index 9efa4b3..13acfa6 100644
--- a/vendor/github.com/google/go-github/github/git_trees.go
+++ b/vendor/github.com/google/go-github/github/git_trees.go
@@ -17,7 +17,7 @@ func (t Tree) String() string {
return Stringify(t)
}
-// TreeEntry represents the contents of a tree structure. TreeEntry can
+// TreeEntry represents the contents of a tree structure. TreeEntry can
// represent either a blob, a commit (in the case of a submodule), or another
// tree.
type TreeEntry struct {
@@ -35,7 +35,7 @@ func (t TreeEntry) String() string {
// GetTree fetches the Tree object for a given sha hash from a repository.
//
-// GitHub API docs: http://developer.github.com/v3/git/trees/#get-a-tree
+// GitHub API docs: https://developer.github.com/v3/git/trees/#get-a-tree
func (s *GitService) GetTree(owner string, repo string, sha string, recursive bool) (*Tree, *Response, error) {
u := fmt.Sprintf("repos/%v/%v/git/trees/%v", owner, repo, sha)
if recursive {
@@ -53,7 +53,7 @@ func (s *GitService) GetTree(owner string, repo string, sha string, recursive bo
return nil, resp, err
}
- return t, resp, err
+ return t, resp, nil
}
// createTree represents the body of a CreateTree request.
@@ -62,11 +62,11 @@ type createTree struct {
Entries []TreeEntry `json:"tree"`
}
-// CreateTree creates a new tree in a repository. If both a tree and a nested
+// CreateTree creates a new tree in a repository. If both a tree and a nested
// path modifying that tree are specified, it will overwrite the contents of
// that tree with the new path contents and write a new tree out.
//
-// GitHub API docs: http://developer.github.com/v3/git/trees/#create-a-tree
+// GitHub API docs: https://developer.github.com/v3/git/trees/#create-a-tree
func (s *GitService) CreateTree(owner string, repo string, baseTree string, entries []TreeEntry) (*Tree, *Response, error) {
u := fmt.Sprintf("repos/%v/%v/git/trees", owner, repo)
@@ -85,5 +85,5 @@ func (s *GitService) CreateTree(owner string, repo string, baseTree string, entr
return nil, resp, err
}
- return t, resp, err
+ return t, resp, nil
}