diff --git a/src/BasketFactory.sol b/src/BasketFactory.sol index 0c3d32c..f6fa8bc 100644 --- a/src/BasketFactory.sol +++ b/src/BasketFactory.sol @@ -9,11 +9,13 @@ contract BasketFactory { event NewBasket(address indexed _address, address indexed _creator); - function createBasket() public { + function createBasket() public returns(address) { Basket basket = new Basket(); basket.transferFrom(address(this), msg.sender, 0); baskets.push(address(basket)); emit NewBasket(address(basket), msg.sender); + + return address(basket); } } \ No newline at end of file