Resonant electron effects on trapped electron instabilities