WIP: Initial work on deduplicating the minifigures and parts #57
@ -61,7 +61,7 @@ class BrickMinifigureList(BrickRecordList[BrickMinifigure]):
|
|||||||
return self
|
return self
|
||||||
|
|
||||||
# Load minifigures from a brickset
|
# Load minifigures from a brickset
|
||||||
def load(self, brickset: 'BrickSet', /) -> Self:
|
def from_set(self, brickset: 'BrickSet', /) -> Self:
|
||||||
# Save the brickset
|
# Save the brickset
|
||||||
self.brickset = brickset
|
self.brickset = brickset
|
||||||
|
|
||||||
|
@ -101,7 +101,7 @@ class BrickSet(RebrickableSet):
|
|||||||
|
|
||||||
# Minifigures
|
# Minifigures
|
||||||
def minifigures(self, /) -> BrickMinifigureList:
|
def minifigures(self, /) -> BrickMinifigureList:
|
||||||
return BrickMinifigureList().load(self)
|
return BrickMinifigureList().from_set(self)
|
||||||
|
|
||||||
# Parts
|
# Parts
|
||||||
def parts(self, /) -> BrickPartList:
|
def parts(self, /) -> BrickPartList:
|
||||||
|
Loading…
Reference in New Issue
Block a user