aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/client/joystick_controller.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/joystick_controller.cpp b/src/client/joystick_controller.cpp
index e6a572adb..3e1442793 100644
--- a/src/client/joystick_controller.cpp
+++ b/src/client/joystick_controller.cpp
@@ -186,7 +186,7 @@ void JoystickController::onJoystickConnect(const std::vector<irr::SJoystickInfo>
}
void JoystickController::setLayoutFromControllerName(std::string name) {
- if (lowercase(name).find("xbox") >= 0) {
+ if (lowercase(name).find("xbox") != std::string::npos) {
m_layout = create_xbox_layout();
} else {
m_layout = create_default_layout();