What makes nuclear weapons a reason not to intervene against Russia, but less cause for concern when intervening against China?

Putin has threatened use of nuclear weapons in Ukraine. Xi wants a no-first-use policy. Easy to tell which one is nuts.