Ajax requests working except when quiz is complete