Small code tweaks

Made the code look slightly nicer