Symmetry condition in terms of Lie brackets