1
0
mirror of https://github.com/OpenTTD/OpenTTD synced 2026-01-18 09:52:44 +01:00

Codechange: use std::string_view over std::string for NetworkTextMessage

This commit is contained in:
Rubidium
2025-04-20 11:22:02 +02:00
committed by rubidium42
parent a0e4dab771
commit a0246bc8a7
3 changed files with 3 additions and 2 deletions

View File

@@ -230,7 +230,7 @@ uint8_t NetworkSpectatorCount()
/* This puts a text-message to the console, or in the future, the chat-box,
* (to keep it all a bit more general)
* If 'self_send' is true, this is the client who is sending the message */
void NetworkTextMessage(NetworkAction action, TextColour colour, bool self_send, const std::string &name, const std::string &str, StringParameter &&data)
void NetworkTextMessage(NetworkAction action, TextColour colour, bool self_send, std::string_view name, std::string_view str, StringParameter &&data)
{
std::string message;
StringBuilder builder(message);