summaryrefslogtreecommitdiff
path: root/scene/2d
diff options
context:
space:
mode:
Diffstat (limited to 'scene/2d')
-rw-r--r--scene/2d/joints_2d.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/scene/2d/joints_2d.cpp b/scene/2d/joints_2d.cpp
index 5b14b3e8e1..d8156a0afe 100644
--- a/scene/2d/joints_2d.cpp
+++ b/scene/2d/joints_2d.cpp
@@ -61,9 +61,7 @@ void Joint2D::_update_joint(bool p_only_free) {
if (!body_a || !body_b)
return;
- if (!body_a) {
- SWAP(body_a, body_b);
- }
+ SWAP(body_a, body_b);
joint = _configure_joint(body_a, body_b);