fixes delegate bug