Magnets and Worms

Magnets and worms,
enjoy a strange trait;
when broken apart,
they share the same fate.

The worm should be dead,
the magnet – no pole,
but their parts rearrange,
and the pieces are whole.