+const getEntryInfo = (entry, t) => {
+ if (entry.user && entry.category) {
+ return t('chatBotLog.info.userCat', {
+ category: t(`twitchBot.chatCategories.${entry.category}`),
+ date: getEntryDate(entry),
+ user: getUserName(entry.user),
+ });
+ }
+ if (entry.category) {
+ return t('chatBotLog.info.cat', {
+ category: t(`twitchBot.chatCategories.${entry.category}`),
+ date: getEntryDate(entry),
+ });
+ }
+ if (entry.user) {
+ return t('chatBotLog.info.user', {
+ date: getEntryDate(entry),
+ user: getUserName(entry.user),
+ });
+ }
+ return getEntryDate(entry);
+};
+