They obeyed him because he was saying this not in the presence of the apostles. But how did the Jews beat the apostles if they obeyed him? They obeyed him in the sense that they abandoned their intention to kill them, because they had wanted this and then gave up this desire of theirs, but they beat them, satisfying their anger.
Source: Commentary on Acts