What is the meaning of [Tread on a worm and it will turn]

“The meanest or weakest person is not to be provoked or despised. No creature so small, weak, or contemptible, but if it be injured and abused will endeavour to revenge itself.”, Ray, John (1813). A compleat collection of English proverbs. To which is added, A collection of English words not generally used. [2 pt. Interleaved, with MS. additions by F. Douce].. p. 176.