update to follow ajax call structure