Этот коммит содержится в:
@@ -108,6 +108,11 @@ var RootCmd = &cobra.Command{
|
|||||||
}
|
}
|
||||||
quiet := viper.GetBool("quiet")
|
quiet := viper.GetBool("quiet")
|
||||||
printer.SetQuiet(quiet)
|
printer.SetQuiet(quiet)
|
||||||
|
|
||||||
|
perPage, err := cmd.Flags().GetInt("per-page")
|
||||||
|
if err == nil && perPage > MaxPageSize {
|
||||||
|
printer.PrintError(fmt.Sprintf("Per page value is greater than the maximum allowed. Mattermost might only return %d items.", MaxPageSize))
|
||||||
|
}
|
||||||
},
|
},
|
||||||
PersistentPostRun: func(cmd *cobra.Command, args []string) {
|
PersistentPostRun: func(cmd *cobra.Command, args []string) {
|
||||||
_ = printer.Flush()
|
_ = printer.Flush()
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ import (
|
|||||||
|
|
||||||
const (
|
const (
|
||||||
DefaultPageSize = 200
|
DefaultPageSize = 200
|
||||||
|
MaxPageSize = 200
|
||||||
)
|
)
|
||||||
|
|
||||||
func checkInteractiveTerminal() error {
|
func checkInteractiveTerminal() error {
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user