Skip to content

Commit

Permalink
chore: also update procedures with new error
Browse files Browse the repository at this point in the history
  • Loading branch information
BeksOmega committed Oct 18, 2022
1 parent 9c4948c commit 7eb754b
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions core/procedures.ts
Expand Up @@ -22,7 +22,7 @@ import * as common from './common.js';
import type {Abstract} from './events/events_abstract.js';
import type {BubbleOpen} from './events/events_bubble_open.js';
import * as eventUtils from './events/utils.js';
import type {Field} from './field.js';
import {Field, UnattachedFieldError} from './field.js';
import {Msg} from './msg.js';
import {Names} from './names.js';
import * as utilsXml from './utils/xml.js';
Expand Down Expand Up @@ -182,9 +182,7 @@ export function isNameUsed(
export function rename(this: Field, name: string): string {
const block = this.getSourceBlock();
if (!block) {
throw new Error(
'The field has not yet been attached to its input. ' +
'Call appendField to attach it.');
throw new UnattachedFieldError();
}

// Strip leading and trailing whitespace. Beyond this, all names are legal.
Expand Down

0 comments on commit 7eb754b

Please sign in to comment.