[MM-46694] A/B Test: welcome post (#20926)

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
Julien Tant
2022-10-13 14:23:22 -07:00
коммит произвёл GitHub
родитель a6a44b5824
Коммит 3747d99806
14 изменённых файлов: 230 добавлений и 0 удалений

Просмотреть файл

@@ -72,6 +72,9 @@ type FeatureFlags struct {
PlanUpgradeButtonText string
// A/B Test on posting a welcome message
SendWelcomePost bool
PostPriority bool
}
@@ -99,6 +102,7 @@ func (f *FeatureFlags) SetDefaults() {
f.CallsEnabled = true
f.BoardsProduct = false
f.PlanUpgradeButtonText = "upgrade"
f.SendWelcomePost = true
f.PostPriority = false
}

Просмотреть файл

@@ -44,6 +44,7 @@ const (
PostTypeChannelRestored = "system_channel_restored"
PostTypeEphemeral = "system_ephemeral"
PostTypeChangeChannelPrivacy = "system_change_chan_privacy"
PostTypeWelcomePost = "system_welcome_post"
PostTypeAddBotTeamsChannels = "add_bot_teams_channels"
PostTypeSystemWarnMetricStatus = "warn_metric_status"
PostTypeMe = "me"
@@ -387,6 +388,7 @@ func (o *Post) IsValid(maxPostSize int) *AppError {
PostTypeChangeChannelPrivacy,
PostTypeAddBotTeamsChannels,
PostTypeSystemWarnMetricStatus,
PostTypeWelcomePost,
PostTypeMe:
default:
if !strings.HasPrefix(o.Type, PostCustomTypePrefix) {