had to revert to older copy of code because I changed some things I shouldn't have