Gated communities?: regulating migration in early modern cities