A theory of everything has several things about mathematics to account for.
Firstly, it must account for the fact that mathematics appears to be useful for describing natural law.
Secondly, it must account for the fact that the mathematics man has produced until now cannot be guaranteed to be free of contradictions, allows us to choose between contradictory axioms, and is structurally incomplete. In other words, 'mathematics is in a mess'.