These last two returns seem the same; last `elif` could just be an `else`