Add feature gates where appropriate