Make individual controller actions asynchronous.

This code would be prettier if the conditional were in the loop somehow, maybe-- seems like there's an awful lot of repetition in the two sections of the if...