Skip to content

Commit

Permalink
chore: rename from pr feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
mshanemc committed Apr 2, 2024
1 parent 43515f2 commit 884c72a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/alias.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export abstract class AliasCommand<T> extends SfCommand<T> {
}
}

export const setUnsetErrorHandler = (err: unknown, alias: string, value?: string): AliasResult => {
export const aliasErrorHandler = (err: unknown, alias: string, value?: string): AliasResult => {
const { name, message } =
err instanceof Error
? err
Expand Down
4 changes: 2 additions & 2 deletions src/commands/alias/set.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import { loglevel, parseVarArgs } from '@salesforce/sf-plugins-core';
import { StateAggregator, Messages } from '@salesforce/core';
import { AliasCommand, AliasResults, setUnsetErrorHandler } from '../../alias.js';
import { AliasCommand, AliasResults, aliasErrorHandler } from '../../alias.js';

Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
const messages = Messages.loadMessages('@salesforce/plugin-settings', 'alias.set');
Expand Down Expand Up @@ -43,7 +43,7 @@ export default class AliasSet extends AliasCommand<AliasResults> {
}
return { alias, success: true, value };
} catch (err) {
return setUnsetErrorHandler(err, alias, value);
return aliasErrorHandler(err, alias, value);
}
})
);
Expand Down
4 changes: 2 additions & 2 deletions src/commands/alias/unset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import { Flags, loglevel } from '@salesforce/sf-plugins-core';
import { StateAggregator, Messages } from '@salesforce/core';
import { AliasCommand, AliasResults, setUnsetErrorHandler } from '../../alias.js';
import { AliasCommand, AliasResults, aliasErrorHandler } from '../../alias.js';

Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
const messages = Messages.loadMessages('@salesforce/plugin-settings', 'alias.unset');
Expand Down Expand Up @@ -67,7 +67,7 @@ export default class AliasUnset extends AliasCommand<AliasResults> {
await stateAggregator.aliases.unsetAndSave(alias);
return { alias, value, success: true };
} catch (err) {
return setUnsetErrorHandler(err, alias, value);
return aliasErrorHandler(err, alias, value);
}
})
);
Expand Down

0 comments on commit 884c72a

Please sign in to comment.