Fixing the Javascript to handle test data without response to backend.