From f254f66587f257b7de252644dd73574ad27a32af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sybren=20A=2E=20St=C3=BCvel?= Date: Fri, 3 Jul 2020 17:20:22 +0200 Subject: Cleanup: Editors/Space/Outliner, Clang-Tidy else-after-return fixes This addresses warnings from Clang-Tidy's `readability-else-after-return` rule in the `source/blender/editors/space_outliner` module. No functional changes. --- source/blender/editors/space_outliner/outliner_edit.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'source/blender/editors/space_outliner/outliner_edit.c') diff --git a/source/blender/editors/space_outliner/outliner_edit.c b/source/blender/editors/space_outliner/outliner_edit.c index bee8b28e658..bead8ddcc42 100644 --- a/source/blender/editors/space_outliner/outliner_edit.c +++ b/source/blender/editors/space_outliner/outliner_edit.c @@ -500,14 +500,14 @@ static void id_delete(bContext *C, ReportList *reports, TreeElement *te, TreeSto BKE_reportf(reports, RPT_WARNING, "Cannot delete indirectly linked id '%s'", id->name); return; } - else if (BKE_library_ID_is_indirectly_used(bmain, id) && ID_REAL_USERS(id) <= 1) { + if (BKE_library_ID_is_indirectly_used(bmain, id) && ID_REAL_USERS(id) <= 1) { BKE_reportf(reports, RPT_WARNING, "Cannot delete id '%s', indirectly used data-blocks need at least one user", id->name); return; } - else if (te->idcode == ID_WS) { + if (te->idcode == ID_WS) { BKE_workspace_id_tag_all_visible(bmain, LIB_TAG_DOIT); if (id->tag & LIB_TAG_DOIT) { BKE_reportf( @@ -947,12 +947,10 @@ static int outliner_lib_relocate_invoke_do( ((Library *)tselem->id)->filepath_abs); return OPERATOR_CANCELLED; } - else { - wmOperatorType *ot = WM_operatortype_find( - reload ? "WM_OT_lib_reload" : "WM_OT_lib_relocate", false); - return lib_relocate(C, te, tselem, ot, reload); - } + wmOperatorType *ot = WM_operatortype_find(reload ? "WM_OT_lib_reload" : "WM_OT_lib_relocate", + false); + return lib_relocate(C, te, tselem, ot, reload); } } else { -- cgit v1.2.3