I know this is not part of this PR but this code should be abstracted in a function called buildStatus()