summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPedro Pereira <pmh.pereira@gmail.com>2021-11-24 00:39:32 +0000
committerAndreas Kling <kling@serenityos.org>2021-11-24 13:51:07 +0100
commit2efec90fb7287cf3c7836ed99e5db57157a06cc8 (patch)
treeef52f86b78a856abd781e85c231b95c2f653a2f0
parent302784ebf88ec4dc18da9ce05e9092e91e9df312 (diff)
downloadserenity-2efec90fb7287cf3c7836ed99e5db57157a06cc8.zip
Spider: Replace construct() with TRY(try_create()) pattern
-rw-r--r--Userland/Games/Spider/main.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Games/Spider/main.cpp b/Userland/Games/Spider/main.cpp
index 6c25711de0..2f0c78158d 100644
--- a/Userland/Games/Spider/main.cpp
+++ b/Userland/Games/Spider/main.cpp
@@ -41,7 +41,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
{
TRY(Core::System::pledge("stdio recvfd sendfd rpath unix", nullptr));
- auto app = GUI::Application::construct(arguments);
+ auto app = TRY(GUI::Application::try_create(arguments));
auto app_icon = GUI::Icon::default_icon("app-spider");
Config::pledge_domains("Spider");
@@ -51,7 +51,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
TRY(Core::System::unveil("/res", "r"));
TRY(Core::System::unveil(nullptr, nullptr));
- auto window = GUI::Window::construct();
+ auto window = TRY(GUI::Window::try_create());
window->set_title("Spider");
auto mode = static_cast<Spider::Mode>(Config::read_i32("Spider", "Settings", "Mode", static_cast<int>(Spider::Mode::SingleSuit)));