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

Fix formatting #33

Merged
merged 1 commit into from
Oct 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/code/Init.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ namespace AnyPackage.Provider.Msu;

public sealed class Init : IModuleAssemblyInitializer, IModuleAssemblyCleanup
{
private readonly Guid _id = new Guid("314633fe-c7e9-4eeb-824b-382a8a4e92b8");
private readonly Guid _id = new("314633fe-c7e9-4eeb-824b-382a8a4e92b8");

public void OnImport()
{
Expand Down
6 changes: 3 additions & 3 deletions src/code/MsuProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@

namespace AnyPackage.Provider.Msu;

[PackageProvider("Msu", PackageByName = false, FileExtensions = new string[] { ".msu" })]
[PackageProvider("Msu", PackageByName = false, FileExtensions = [".msu"])]
public sealed class MsuProvider : PackageProvider, IFindPackage, IGetPackage, IInstallPackage, IUninstallPackage
{
public void FindPackage(PackageRequest request)
Expand All @@ -28,12 +28,12 @@ public void FindPackage(PackageRequest request)
}

string line;
Dictionary<string, object> metadata = new Dictionary<string, object>();
Dictionary<string, object> metadata = [];
using var reader = file.OpenText();

while ((line = reader.ReadLine()) is not null)
{
var values = line.Split(new char[] { '=' }, 2);
var values = line.Split(['='], 2);
var key = values[0].Replace(" ", "");

// Remove quotes around value
Expand Down