diff --git a/creational/abstract_factory/motorbike_factory.go b/creational/abstract_factory/motorbike_factory.go index 4fccb2f..d474da1 100644 --- a/creational/abstract_factory/motorbike_factory.go +++ b/creational/abstract_factory/motorbike_factory.go @@ -12,7 +12,7 @@ const ( type MotorbikeFactory struct{} -func (m *MotorbikeFactory) Build(v int) (Vehicle, error) { +func (m *MotorbikeFactory) NewVehicle(v int) (Vehicle, error) { switch v { case SportMotorbikeType: return new(SportMotorbike), nil