Updated toString to contain less code