An epidemic model involving a threshold