Now uncommented recordData to send data to server