Skip to content

Commit

Permalink
go fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
DataDrake committed May 12, 2019
1 parent 04099c0 commit 7853c5a
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
26 changes: 13 additions & 13 deletions providers/github/graphql.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,21 +86,21 @@ type RepoQueryResult struct {
func (rqr RepoQueryResult) Convert(name string) (rs *results.ResultSet) {
rs = results.NewResultSet(name)
for _, tag := range rqr.Data.Repository.Refs.Nodes {
pre := false
var published time.Time
pre := false
var published time.Time
for _, node := range rqr.Data.Repository.Releases.Nodes {
if node.Tag.Name == tag.Name {
if node.IsPrerelease {
pre = true
}
published, _ = time.Parse(time.RFC3339, node.PublishedAt)
}
if node.Tag.Name == tag.Name {
if node.IsPrerelease {
pre = true
}
published, _ = time.Parse(time.RFC3339, node.PublishedAt)
}
}
if pre {
continue
}
r := results.NewResult(name, tag.Name, fmt.Sprintf(SourceFormat, name, tag.Name), published)
rs.AddResult(r)
if pre {
continue
}
r := results.NewResult(name, tag.Name, fmt.Sprintf(SourceFormat, name, tag.Name), published)
rs.AddResult(r)
}
return
}
Expand Down
2 changes: 1 addition & 1 deletion providers/kde/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ func (c Provider) Releases(name string) (rs *results.ResultSet, s results.Status
buff := bytes.NewBuffer(listing)
pieces := strings.Split(name, "/")
pieces2 := strings.Split(pieces[len(pieces)-1], "-")
name = strings.Join(pieces2[0:len(pieces2)-1], "-")
name = strings.Join(pieces2[0:len(pieces2)-1], "-")
var searchPrefix string
switch len(pieces) {
case 4:
Expand Down

0 comments on commit 7853c5a

Please sign in to comment.