applying SRP to some functions