refactor: modernise routes.isUnlisted
1 file changed, 1 insertion(+), 7 deletions(-)
changed files
M routes/util.go → routes/util.go
@@ -36,13 +36,7 @@ return } func (d *deps) isUnlisted(name string) bool { - for _, i := range d.c.Repo.Unlisted { - if name == i { - return true - } - } - - return false + return slices.Contains(d.c.Repo.Unlisted, name) } func (d *deps) isNotAllowed(name string) bool {