fix(quotas): correct custom-environment plan gating and require valid licenses (#936)