Ugh, is this really the best way to do this?