updated

logic now working