Possibly fixed looping issue