diff options
author | vaxerski <[email protected]> | 2022-05-30 14:18:46 +0200 |
---|---|---|
committer | vaxerski <[email protected]> | 2022-05-30 14:18:46 +0200 |
commit | 7167be9c482760c81f70153f4457f60cca4e9c80 (patch) | |
tree | c31ba4c6000ddece2fae693eec644fceb44eea3d | |
parent | e81790f357e387515467761f0bc3c032a1bb771f (diff) | |
download | Hyprland-7167be9c482760c81f70153f4457f60cca4e9c80.tar.gz Hyprland-7167be9c482760c81f70153f4457f60cca4e9c80.zip |
Fix relative IDs in movetoworkspace crashing
-rw-r--r-- | src/Compositor.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp index 29e2f188..0b60369d 100644 --- a/src/Compositor.cpp +++ b/src/Compositor.cpp @@ -820,8 +820,8 @@ CWorkspace* CCompositor::getWorkspaceByString(const std::string& str) { } try { - int id = std::stoi(str); - return getWorkspaceByID(id); + std::string name = ""; + return getWorkspaceByID(getWorkspaceIDFromString(str, name)); } catch (std::exception& e) { Debug::log(ERR, "Error in getWorkspaceByString, invalid id"); } |