another refactoring

Signed-off-by: Ellie Schneiders <ems2141@gmail.com>