MM52237 - prevent fetching fileCount from unnecessary places (#23981)

* MM52237 - prevent call file count from unnecesary places

* rename the variable to make more clear function signature
Этот коммит содержится в:
Pablo Andrés Vélez Vidal
2023-07-27 11:48:36 +02:00
коммит произвёл GitHub
родитель 93b7957de3
Коммит 525c21a9d3
6 изменённых файлов: 12 добавлений и 12 удалений

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

@@ -1739,8 +1739,8 @@ export default class Client4 {
);
};
getChannelStats = (channelId: string, excludeFilesCount = false) => {
const param = excludeFilesCount ? `?exclude_files_count=${excludeFilesCount}` : '';
getChannelStats = (channelId: string, includeFileCount = false) => {
const param = !includeFileCount ? '?exclude_files_count=true' : '';
return this.doFetch<ChannelStats>(
`${this.getChannelRoute(channelId)}/stats${param}`,
{method: 'get'},