See the error of (one's) ways phrase
To become aware of the fact that one has made a mistake or misbehaved and determine to behave in a better way.
His parents were happy when they knew that he had seen the error of his ways.
Prisoners who see the error of their ways are likely to be released early.
John was praised by his teacher for seeing the error of his ways.
The verb "see" must be conjugated according to its tense.
The origin of this phrase is not clear.