Court pact on child migrant detention