Fixed error in Spike Cataloger

time_intervals function now finds the end-point of a spike successfully
again.