checking errr in handle conn