improved cleanup (fix)

forgot to set the new values to the pi.