Changed up coding to cleanest level