mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-06-07 11:54:59 +00:00
perf: minimize temporary strings for better performance (#1255)
This commit is contained in:
parent
53a55467f1
commit
48bb8e91de
8 changed files with 35 additions and 23 deletions
|
@ -1,4 +1,5 @@
|
|||
using System.ComponentModel.DataAnnotations;
|
||||
using System;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.IO;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
|
@ -31,7 +32,7 @@ namespace SourceGit.ViewModels
|
|||
{
|
||||
_repo = repo;
|
||||
_revision = commit.SHA;
|
||||
_saveFile = $"archive-{commit.SHA.Substring(0, 10)}.zip";
|
||||
_saveFile = $"archive-{commit.SHA.AsSpan().Slice(0, 10)}.zip";
|
||||
BasedOn = commit;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue