Fix: Python: Empty list of drawing.strokes doesn't have length of 0
The API would return `None` if the number of strokes in the drawing was `0`. Instead this should return a slice that has a length of 0 to be consistent.
This commit is contained in:
@@ -1421,5 +1421,4 @@ class GreasePencilDrawing(_StructRNA):
|
||||
"""
|
||||
from _bpy_internal.grease_pencil.stroke import GreasePencilStrokeSlice
|
||||
num_strokes = self.attributes.domain_size('CURVE')
|
||||
if num_strokes > 0:
|
||||
return GreasePencilStrokeSlice(self, 0, num_strokes)
|
||||
return GreasePencilStrokeSlice(self, 0, num_strokes)
|
||||
|
||||
Reference in New Issue
Block a user