Skip to content

Commit 3713bc0

Browse files
committed
extract constant for max page size default, double to 100
1 parent 5c871f9 commit 3713bc0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

cli/server.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ import (
2121
"github.com/coder/code-marketplace/storage"
2222
)
2323

24+
const maxPageSizeDefault int = 100
25+
2426
func server() *cobra.Command {
2527
var (
2628
address string
@@ -138,7 +140,7 @@ func server() *cobra.Command {
138140
}
139141

140142
cmd.Flags().StringVar(&extdir, "extensions-dir", "", "The path to extensions.")
141-
cmd.Flags().IntVar(&maxpagesize, "max-page-size", 50, "The maximum number of pages to request")
143+
cmd.Flags().IntVar(&maxpagesize, "max-page-size", maxPageSizeDefault, "The maximum number of pages to request")
142144
cmd.Flags().StringVar(&artifactory, "artifactory", "", "Artifactory server URL.")
143145
cmd.Flags().StringVar(&repo, "repo", "", "Artifactory repository.")
144146
cmd.Flags().StringVar(&address, "address", "127.0.0.1:3001", "The address on which to serve the marketplace API.")

0 commit comments

Comments
 (0)