From c2d5fc91ecc79993fd03b7ea0ef17e1b421b0265 Mon Sep 17 00:00:00 2001 From: Philipp Oeser Date: Fri, 6 Oct 2023 16:19:03 +0200 Subject: [PATCH] Fix #113346: Append/Link fails if no name is specified Caused by fa29d28d731e . Code used to work like this: - if items are selected, these are considered for Append/Link -- name is ignored in that case - if no items are selected, the name is considered for Append/Link Selection with the mouse usually sets the name as well (unnecessarily even) -- so this still worked fine even after fa29d28d731e . Selecting All with 'A' does not set a name, but code from fa29d28d731e added the additional check to the early out and reports an error. Now remove the additional check again, the logic following that code takes care of handling ether selected items or a provided name just fine. --- source/blender/windowmanager/intern/wm_files_link.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/blender/windowmanager/intern/wm_files_link.cc b/source/blender/windowmanager/intern/wm_files_link.cc index 9e9005820e8..676c8a41c0c 100644 --- a/source/blender/windowmanager/intern/wm_files_link.cc +++ b/source/blender/windowmanager/intern/wm_files_link.cc @@ -230,7 +230,7 @@ static int wm_link_append_exec(bContext *C, wmOperator *op) BKE_reportf(op->reports, RPT_ERROR, "'%s': cannot use current file as library", filepath); return OPERATOR_CANCELLED; } - if (!group || !name) { + if (!group) { BKE_reportf(op->reports, RPT_ERROR, "'%s': nothing indicated", filepath); return OPERATOR_CANCELLED; } -- 2.30.2