diff options
author | Sybren A. Stüvel <sybren@blender.org> | 2020-07-03 18:30:31 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@blender.org> | 2020-07-03 18:42:46 +0300 |
commit | 33a74941c5fd4efb6eefcaace3315d3e2b65681f (patch) | |
tree | 2d3da68b73e4419750c7f767bbb78bf1a303ad18 /source/blender/editors/physics/rigidbody_constraint.c | |
parent | 367034f210137754ab4f07a0e7793066d2b69e59 (diff) |
Cleanup: Editors, Clang-Tidy else-after-return fixes
This addresses warnings from Clang-Tidy's `readability-else-after-return`
rule in the `source/blender/editors` module.
No functional changes.
Diffstat (limited to 'source/blender/editors/physics/rigidbody_constraint.c')
-rw-r--r-- | source/blender/editors/physics/rigidbody_constraint.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/source/blender/editors/physics/rigidbody_constraint.c b/source/blender/editors/physics/rigidbody_constraint.c index a59b031298c..4939bf0086b 100644 --- a/source/blender/editors/physics/rigidbody_constraint.c +++ b/source/blender/editors/physics/rigidbody_constraint.c @@ -68,9 +68,7 @@ static bool ED_operator_rigidbody_con_active_poll(bContext *C) Object *ob = ED_object_active_context(C); return (ob && ob->rigidbody_constraint); } - else { - return false; - } + return false; } static bool ED_operator_rigidbody_con_add_poll(bContext *C) @@ -151,9 +149,7 @@ static int rigidbody_con_add_exec(bContext *C, wmOperator *op) /* done */ return OPERATOR_FINISHED; } - else { - return OPERATOR_CANCELLED; - } + return OPERATOR_CANCELLED; } void RIGIDBODY_OT_constraint_add(wmOperatorType *ot) @@ -193,9 +189,7 @@ static int rigidbody_con_remove_exec(bContext *C, wmOperator *op) BKE_report(op->reports, RPT_ERROR, "Object has no Rigid Body Constraint to remove"); return OPERATOR_CANCELLED; } - else { - ED_rigidbody_constraint_remove(bmain, scene, ob); - } + ED_rigidbody_constraint_remove(bmain, scene, ob); /* send updates */ WM_event_add_notifier(C, NC_OBJECT | ND_TRANSFORM, NULL); |