Whenever I have an incident like this, I just force myself to do it CORRECTLY the next time around and all is well.. With the exception of the whoops. I used to be real fast in the whoops at my local track, only a few pros were faster.. Until I swapped at the end of the section one time and hit the base of a tree square-on, tapped in 3rd gear. This scared the crap out of me, as it seemed that I was doing everything the same as I always do (successfully). I've never regained the confidence that I lost in that crash.. Ever since then I'm average at best in those whoops. I feel I can pick up the pace, but something tells me not to, every time. I still feel like it could happen again, and last time I was extremely lucky to escape severe injury and walk away from that one.
I'll still jump the 70' doubles and 106' quad jump (on occasion), but I won't blitz the whoops. If I wadded it on the 106' quad jump for no apparent (to me) reason, I probably wouldn't do it anymore either as it would not feel safe.
You should get the confidence back, but don't push yourself too much, ride safe and smart. Most of us don't get paid to do this, and we have to show up at work on Monday morning.