since the throw above will exit, we can remove the `else` bit here. Then, if it fits on one line, we can change the first condition to have no { } (that is, `if (json.length < 1) throw new StateError('No open pages');`)