Refactored vagrant fix out and cleaned up some logic