* Basic framework for use of feature flags. Enviroment variable overrides. * Use Apperr instead of error number increments. * Undo random viper change. * Update model/config_test.go Co-authored-by: Jesse Hallam <jesse.hallam@gmail.com> Co-authored-by: Jesse Hallam <jesse.hallam@gmail.com>
15 строки
351 B
Go
15 строки
351 B
Go
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
|
// See LICENSE.txt for license information.
|
|
|
|
package model
|
|
|
|
type FeatureFlags struct {
|
|
// Exists only for unit and manual testing.
|
|
// When set to a value, will be returned by the ping endpoint.
|
|
TestFeature string
|
|
}
|
|
|
|
func (f *FeatureFlags) SetDefaults() {
|
|
f.TestFeature = "off"
|
|
}
|