fixed recursive empty shift ajax call