mirror of https://github.com/go-gitea/gitea.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
13d5d2e711
This pull request is a minor code cleanup. From the Go specification (https://go.dev/ref/spec#For_range): > "1. For a nil slice, the number of iterations is 0." > "3. If the map is nil, the number of iterations is 0." `len` returns 0 if the slice or map is nil (https://pkg.go.dev/builtin#len). Therefore, checking `len(v) > 0` before a loop is unnecessary. --- At the time of writing this pull request, there wasn't a lint rule that catches these issues. The closest I could find is https://staticcheck.dev/docs/checks/#S103 Signed-off-by: Eng Zer Jun <engzerjun@gmail.com> |
1 year ago | |
---|---|---|
.. | ||
actions | 1 year ago | |
setting | 1 year ago | |
activity.go | 2 years ago | |
attachment.go | 1 year ago | |
blame.go | 1 year ago | |
branch.go | 1 year ago | |
cherry_pick.go | 2 years ago | |
commit.go | 1 year ago | |
compare.go | 1 year ago | |
download.go | 2 years ago | |
editor.go | 1 year ago | |
editor_test.go | 1 year ago | |
find.go | 2 years ago | |
helper.go | 1 year ago | |
helper_test.go | 1 year ago | |
http.go | 1 year ago | |
http_test.go | 2 years ago | |
issue.go | 1 year ago | |
issue_content_history.go | 1 year ago | |
issue_dependency.go | 2 years ago | |
issue_label.go | 1 year ago | |
issue_label_test.go | 1 year ago | |
issue_lock.go | 2 years ago | |
issue_pin.go | 2 years ago | |
issue_stopwatch.go | 1 year ago | |
issue_test.go | 2 years ago | |
issue_timetrack.go | 1 year ago | |
issue_watch.go | 1 year ago | |
main_test.go | 1 year ago | |
middlewares.go | 1 year ago | |
migrate.go | 1 year ago | |
milestone.go | 1 year ago | |
packages.go | 1 year ago | |
patch.go | 2 years ago | |
projects.go | 1 year ago | |
projects_test.go | 1 year ago | |
pull.go | 1 year ago | |
pull_review.go | 1 year ago | |
release.go | 1 year ago | |
release_test.go | 1 year ago | |
render.go | 2 years ago | |
repo.go | 1 year ago | |
search.go | 2 years ago | |
topic.go | 1 year ago | |
treelist.go | 2 years ago | |
view.go | 1 year ago | |
view_test.go | 2 years ago | |
wiki.go | 1 year ago | |
wiki_test.go | 1 year ago |