Fix spawn calls for API changes