1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 20:57:35 +00:00

Minesweeper: Replace construct() with TRY(try_create()) pattern

This commit is contained in:
Pedro Pereira 2021-11-24 00:39:04 +00:00 committed by Andreas Kling
parent 0a800cc1bb
commit 36056c1cba

View file

@ -26,7 +26,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
{
TRY(Core::System::pledge("stdio rpath recvfd sendfd unix", nullptr));
auto app = GUI::Application::construct(arguments);
auto app = TRY(GUI::Application::try_create(arguments));
Config::pledge_domains("Minesweeper");
@ -37,7 +37,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
auto app_icon = GUI::Icon::default_icon("app-minesweeper");
auto window = GUI::Window::construct();
auto window = TRY(GUI::Window::try_create());
window->set_resizable(false);
window->set_title("Minesweeper");
window->resize(139, 175);