Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mz/w 14720788/diff refresh to sf #5418

Merged
merged 5 commits into from
Feb 16, 2024

Conversation

mingxuanzhangsfdx
Copy link
Member

What does this PR do?

Change the style of diff files, folders & refresh sobject to sf

What issues does this PR fix or reference?

@W-14720788@

Functionality Before

sfdx style

Functionality After

sf style

@CristiCanizales CristiCanizales requested review from CristiCanizales and removed request for smarvez February 14, 2024 14:53
Copy link
Contributor

@CristiCanizales CristiCanizales left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Just one comment :)

defaultUsernameorAlias,
filePart,
filePart
)
);
} catch (err) {
notificationService.showErrorMessage(err.message);
await notificationService.showErrorMessage(err.message);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why this await? the function doesn't return a promise

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From what I learnt, the return type Thenable also needs await. My vscode lint check also reminds me to do so.

telemetryService.sendException('unsupported_type_on_diff', errorMessage);
notificationService.showErrorMessage(errorMessage);
await notificationService.showErrorMessage(errorMessage);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

@@ -38,13 +38,15 @@ export async function forceSourceDiff(sourceUri?: vscode.Uri) {

const defaultUsernameorAlias = WorkspaceContext.getInstance().username;
if (!defaultUsernameorAlias) {
notificationService.showErrorMessage(nls.localize('missing_default_org'));
await notificationService.showErrorMessage(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and here

telemetryService.sendException('unsupported_type_on_diff', errorMessage);
notificationService.showErrorMessage(errorMessage);
await notificationService.showErrorMessage(errorMessage);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and here

@@ -72,7 +74,9 @@ export async function forceSourceFolderDiff(explorerPath: vscode.Uri) {

const username = WorkspaceContext.getInstance().username;
if (!username) {
notificationService.showErrorMessage(nls.localize('missing_default_org'));
await notificationService.showErrorMessage(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and here (?

@CristiCanizales
Copy link
Contributor

QE notes:

  • Three commands continue working as expected ✅
  • refresh sobjects on startup ✅
  • recreates sobjects folder if it's not there ✅

Copy link
Contributor

@CristiCanizales CristiCanizales left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for helping with this!
:shipit:

@mingxuanzhangsfdx mingxuanzhangsfdx merged commit 8ce5373 into develop Feb 16, 2024
12 checks passed
@mingxuanzhangsfdx mingxuanzhangsfdx deleted the mz/w-14720788/diff-refresh-to-sf branch February 16, 2024 19:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants