connection fixes and parseInt change to parseDouble