Skip to content

Commit

Permalink
fix: golang syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
moul committed Nov 14, 2018
1 parent c24c6a4 commit 2e39326
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions server/handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,9 +157,11 @@ func (s *Server) ListReleaseIOS(c echo.Context) error {
branchKind = "master"
}

diff := `<span class="btn">N/A</span>`
//diff := `<span class="btn">N/A</span>`
diff := ""
if build != nil && build.Compare != nil {
diff = fmt.Sprintf(`<a class="btn" href="%s">diff</a>`, *build.Compare)
}

elems := []string{
fmt.Sprintf(`<td class="td-title"><a href="%s" title="%s">%s</a><br />%s</td>`, branchLink, hover, branchName, build.User.Login),
Expand All @@ -170,7 +172,7 @@ func (s *Server) ListReleaseIOS(c echo.Context) error {
// FIXME: create a link /itms/release/TOKEN/ID instead of /itms/release/TOKEN/BRANCH (this way we can handle multiple artifacts per branch)
}

html += fmt.Sprintf(`<tr class="tr-%s">%s</tr>`, branchKind, elems)
html += fmt.Sprintf(`<tr class="tr-%s">%s</tr>`, branchKind, strings.Join(elems, " "))
}
html += `</tbody></table>`
html += `</div></body></html>`
Expand Down

0 comments on commit 2e39326

Please sign in to comment.