The source is as follows
The Book of Rites The Doctrine of the Mean:
"Tao, too, can't be followed for a moment; Parting is not Tao. Therefore, a gentleman is wary of what he has not seen and afraid of what he has never heard of. He didn't see what he didn't see, and he couldn't show what he didn't see. A gentleman is cautious. "
The general meaning is: "Tao is inseparable, and it is not Tao that separates." Therefore, a gentleman should be careful of his words and deeds when others can't see or hear. "
The vernacular means that a gentleman should pay attention to his words and deeds even when he is alone.