Split extended opcode with splitFirst instead of split

This commit is contained in:
Christopher Willis-Ford 2018-09-12 17:02:18 -04:00
parent 8602d5798a
commit 346e1383ed

View file

@ -1837,7 +1837,7 @@ class Runtime extends EventEmitter {
* @property {string} [label] - the label for this opcode if `labelFn` is absent
*/
getLabelForOpcode (extendedOpcode) {
const [category, opcode] = extendedOpcode.split('_');
const [category, opcode] = StringUtil.splitFirst(extendedOpcode, '_');
if (!(category && opcode)) return;
const categoryInfo = this._blockInfo.find(ci => ci.id === category);