Changed main to fit The Garrett's requirements