Fixed the hub destruction bug.