Fix some Salt stuff and omit_code option in API.