Changed a few functions, and removed some stuff from testing.js