Logic is a form a mathematics, and understanding logic is essential. Indeed, for many programmers, that's the extent of the math they know and use. And that's what limits them. There is so much more.
Also, math and logic are obviously related, but logic is not "a form of mathematics". If anything, mathematics is a form of logic.