Skip to content

Commit f56f33e

Browse files
committed
Fixed variable crossover causing #196
1 parent 092dabf commit f56f33e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

cmd/api.go

+4-2
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ var prettyPrint bool
2121
var autoPaginate int = 0
2222
var port int
2323

24+
var generateCount int
25+
2426
var apiCmd = &cobra.Command{
2527
Use: "api",
2628
Short: "Used to interface with the Twitch API",
@@ -100,7 +102,7 @@ func init() {
100102

101103
startCmd.Flags().IntVarP(&port, "port", "p", 8080, "Defines the port that the mock API will run on.")
102104

103-
generateCmd.Flags().IntVarP(&count, "count", "c", 10, "Defines the number of fake users to generate.")
105+
generateCmd.Flags().IntVarP(&generateCount, "count", "c", 25, "Defines the number of fake users to generate.")
104106
}
105107

106108
func cmdRun(cmd *cobra.Command, args []string) {
@@ -142,5 +144,5 @@ func mockStartRun(cmd *cobra.Command, args []string) {
142144
}
143145

144146
func generateMockRun(cmd *cobra.Command, args []string) {
145-
generate.Generate(count)
147+
generate.Generate(generateCount)
146148
}

0 commit comments

Comments
 (0)