Move curl check to constructor