voxel/voxel-commands

TypeError: arguments.slice is not a function

deathcap opened this issue · 0 comments

Chrome 50.0.2661.94, typed .cerative (misspelled .creative), crashed in:

    this.handlers = {
      //undefined: (command, args...) => { // TODO: spread
      'undefined': (command) => {
        const args = arguments.slice(1); // TypeError: arguments.slice is not a function
        this.console.log(`Invalid command ${command} ${args.join(' ')}`);
      },

screen shot 2016-05-09 at 8 12 04 pm

arguments
[Game, Object]
arguments.slice
undefined

may want to switch to the spread argument, as the comment suggests, now that it is implemented in Chrome 50 / Node v6 (ES6 support in V8 5.0)