it almost works, but there's an issue with the name variable