f543bd9bdf
For ChangeInfo it is expected that all labels from the 'permitted_labels' field are contained in the 'labels' field. If this was not the case the UI failed with the following error: SEVERE: Exception caught: (TypeError) : Cannot read property 'values' of undefined Class$S471: Exception caught: (TypeError) : Cannot read property 'values' of undefined at Unknown.Throwable_2(gerrit_ui-0.js) ... Caused by: Class$S171: (TypeError) : Cannot read property 'values' of undefined at Unknown.$_values(gerrit_ui-0.js) at Unknown.$values_0(gerrit_ui-0.js) at Unknown.$valueSet(gerrit_ui-0.js) at Unknown.renderLabels(gerrit_ui-0.js) at Unknown.ReplyBox(gerrit_ui-0.js) at Unknown.onReply_2(gerrit_ui-0.js) ... This error prevents posting of replies on a change. Although this should never happen, the UI should not fail like this. Hence handle this case. This means the voting buttons for this label would be missing, but at least posting a reply (other labels, comments) is still working. Change-Id: I27d3ce0784028c332378f6a390ab48d906fe35ea Signed-off-by: Edwin Kempin <ekempin@google.com>