Tidy up and reorganise

Signed-off-by: Gray Remlin <gryrmln@gmail.com>