`logs.join('\n');` returns a string and the array referred to by `logs` goes unchanged here. So, this is an unnecessary operation.