- optin refactor