mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 01:17:35 +00:00
LibChess: Convert Commands to use String and propagate errors
This commit is contained in:
parent
6576bbc098
commit
29c41e953b
4 changed files with 101 additions and 98 deletions
|
@ -22,8 +22,9 @@ Endpoint::Endpoint(NonnullRefPtr<Core::IODevice> in, NonnullRefPtr<Core::IODevic
|
|||
|
||||
void Endpoint::send_command(Command const& command)
|
||||
{
|
||||
dbgln_if(UCI_DEBUG, "{} Sent UCI Command: {}", class_name(), DeprecatedString(command.to_deprecated_string().characters(), Chomp));
|
||||
m_out->write(command.to_deprecated_string());
|
||||
auto command_string = command.to_string().release_value_but_fixme_should_propagate_errors();
|
||||
dbgln_if(UCI_DEBUG, "{} Sent UCI Command: {}", class_name(), command_string);
|
||||
m_out->write(command_string);
|
||||
}
|
||||
|
||||
void Endpoint::event(Core::Event& event)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue