cleaned up code, added localization to the remaining methods without it