Index name was incorrect - fixed.
Clean up  alot of bad code