summaryrefslogtreecommitdiff
path: root/shortcuts
diff options
authorMC Return <mc.return@gmx.net>2013-02-20 23:01:15 +0100
committerMC Return <mc.return@gmx.net>2013-02-20 23:01:15 +0100
commit2b2b619ee001e1fed18660772b0e5bd3d6be50cd (patch)
tree9baec2432563e1b3947fcdd41bf02236cf27878c /shortcuts
parent2ccc6edd779f7f4eacf000b4b9a9261cca3a073b (diff)
size_t index is always unsigned, so the check if it is >= 0
is redundant and can be removed The else branch will never be executed so it can be removed as well (bzr r3166.2.3)
Diffstat (limited to 'shortcuts')
-rw-r--r--shortcuts/ShortcutHintPrivate.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/shortcuts/ShortcutHintPrivate.cpp b/shortcuts/ShortcutHintPrivate.cpp
index 11e6b2388..8ca036298 100644
--- a/shortcuts/ShortcutHintPrivate.cpp
+++ b/shortcuts/ShortcutHintPrivate.cpp
@@ -35,10 +35,8 @@ namespace impl
std::string GetMetaKey(std::string const& scut)
{
size_t index = scut.find_last_of( ">");
- if (index >= 0)
- return std::string(scut.begin(), scut.begin() + index + 1);
- else
- return "";
+
+ return std::string(scut.begin(), scut.begin() + index + 1);
}
std::string FixShortcutFormat(std::string const& scut)