Skip to content

Commit

Permalink
workspace: fix workspace name selector returning true early (#5571)
Browse files Browse the repository at this point in the history
  • Loading branch information
thejch committed Apr 13, 2024
1 parent 34396f5 commit 582d623
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/desktop/Workspace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -334,10 +334,10 @@ bool CWorkspace::matchesStaticSelector(const std::string& selector_) {

prop = prop.substr(2, prop.length() - 3);

if (prop.starts_with("s:"))
return m_szName.starts_with(prop.substr(2));
if (prop.starts_with("e:"))
return m_szName.ends_with(prop.substr(2));
if (prop.starts_with("s:") && !m_szName.starts_with(prop.substr(2)))
return false;
if (prop.starts_with("e:") && !m_szName.ends_with(prop.substr(2)))
return false;

const auto WANTSNAMED = configStringToInt(prop);

Expand Down

0 comments on commit 582d623

Please sign in to comment.