fixed slave constructor