Reduce number of calls to IsCRTEnabled (#23963)

In a single createPost flow, there were
3 separate calls to App.IsCRTEnabled. This
showed up very slightly in the CPU profiles.

Not a big deal, but good to get it out of
the way.

```release-note
NONE
```
Этот коммит содержится в:
Agniva De Sarker
2023-07-10 10:18:55 +05:30
коммит произвёл GitHub
родитель b5a3eee739
Коммит 49e1d039f5
6 изменённых файлов: 15 добавлений и 14 удалений

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

@@ -93,7 +93,7 @@ func TestExportUserChannels(t *testing.T) {
Value: "true",
}
_, appErr := th.App.MarkChannelsAsViewed(th.Context, []string{th.BasicPost.ChannelId}, user.Id, "", true)
_, appErr := th.App.MarkChannelsAsViewed(th.Context, []string{th.BasicPost.ChannelId}, user.Id, "", true, th.App.IsCRTEnabledForUser(th.Context, user.Id))
require.Nil(t, appErr)
var preferences model.Preferences