Fixed some stuff with regards to loops.