GP: Fix unreported change material operator error
The first material of the list could not be assigned.
This commit is contained in:
parent
81a7d3cd07
commit
310f1b0579
|
@ -1371,7 +1371,7 @@ static int gp_stroke_change_color_exec(bContext *C, wmOperator *op)
|
|||
}
|
||||
/* try to find slot */
|
||||
int idx = BKE_gpencil_get_material_index(ob, ma) - 1;
|
||||
if (idx <= 0) {
|
||||
if (idx < 0) {
|
||||
return OPERATOR_CANCELLED;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue