modifications?
cleaned up version