Update to make fully self contained.
Removal of extra code no longer needed