Debugging uploadScript