Skip to content

Commit 2f581af

Browse files
CopilotJusterZhu
andcommitted
Remove redundant operations and optimize JSON serialization
Co-authored-by: JusterZhu <11714536+JusterZhu@users.noreply.github.com>
1 parent 6bf5864 commit 2f581af

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

src/ViewModels/ExtensionViewModel.cs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ await ZipUtility.CompressDirectoryAsync(
280280
ConfigModel.FileSize = fileInfo.Length;
281281

282282
// Serialize manifest to JSON
283-
var manifestJson = JsonConvert.SerializeObject(ConfigModel, Formatting.Indented);
283+
var manifestJson = JsonConvert.SerializeObject(ConfigModel);
284284
if (!string.IsNullOrEmpty(manifestJson))
285285
{
286286
// Add manifest.json to the zip file
@@ -347,9 +347,6 @@ private async Task AddCustomPropertyAction()
347347
// Clear input fields
348348
NewCustomPropertyKey = string.Empty;
349349
NewCustomPropertyValue = string.Empty;
350-
351-
// Notify command to re-evaluate its CanExecute state
352-
AddCustomPropertyCommand.NotifyCanExecuteChanged();
353350
}
354351
catch (Exception ex)
355352
{

0 commit comments

Comments
 (0)