changed index to debug version