had to fix a few things in script