breaking up smaller methods

Signed-off-by: Adam Stokes <adam.stokes@ubuntu.com>