maybe use a switch statement here?