Skip to content

Conversation

@oobjectt
Copy link
Contributor

@oobjectt oobjectt commented Dec 8, 2022

Enabled the Report button when a user asks a Habbo Guide / Alpha / Guardian for help.

imagen

Copy link
Collaborator

@s074 s074 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one is almost good to go, only suggested one change this time around, good job 👍

Copy link
Collaborator

@s074 s074 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I requested some cleanup changes since the GUIDE report doesn't need any chatlogs

{
const parser = event.getParser();

addMessengerEntry({ id: -1, webId: parser.senderId, entityId: -1, name: userName, timestamp: ChatHistoryCurrentDate(), type: ChatEntryType.TYPE_IM, roomId: !roomSession ? 0 : roomSession.roomId, message: parser.chatMessage });
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since we aren't sending any chatlogs we probably don't need to store the helper chatlog

SendMessageComposer(new CallForHelpFromPhotoMessageComposer(activeReport.extraData, activeReport.cfhTopic, activeReport.roomId, GetSessionDataManager().userId, activeReport.roomObjectId));
break;
case ReportType.GUIDE:
activeReport.reportedChats.forEach(entry => chats.push(entry.webId, entry.message));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

don't need to append any chats to the active report since the report doesn't need any chatlogs

case ReportType.EMERGENCY:
return chatHistory.filter(chat => (chat.type === ChatEntryType.TYPE_CHAT) && (chat.webId === activeReport.reportedUserId) && (chat.entityType === RoomObjectType.USER));
case ReportType.IM:
case ReportType.GUIDE:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GUIDE report won't need to select any chatlogs so remove this line as well

@oobjectt
Copy link
Contributor Author

Hi @dank074 ! I have cleaned what you asked for.

But right in the file src/components/help/views/SelectReportedChatsView.tsx if I remove the case, clicking the 'Ask for help' button doesn't do anything or get a ticket to the staff.

On the other hand, if we put it as it is, we send it an empty message if it works.

You can check it on your own if you want!

Thanks for the information 👍 

@oobjectt oobjectt requested a review from s074 January 18, 2023 20:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants