it works, but not perfect