cleaned up some logic

Signed-off-by: Alexander Skjolden <alex@plastboks.net>