A better way to do the same thing