Cleaned up the code a bit

Signed-off-by: Wilco van den Brink <wilco.vandenbrink@outlook.com>