Add Guard and slight restructure