mirror of
https://jihulab.com/DGP-Studio/Snap.Hutao.Deployment.git
synced 2025-11-19 21:08:45 +08:00
fix ERROR_MRM_MAP_NOT_FOUND
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
|
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
|
||||||
<metadata>
|
<metadata>
|
||||||
<id>Snap.Hutao.Deployment.Runtime</id>
|
<id>Snap.Hutao.Deployment.Runtime</id>
|
||||||
<version>1.6.0</version>
|
<version>1.7.0</version>
|
||||||
<authors>DGP Studio</authors>
|
<authors>DGP Studio</authors>
|
||||||
<developmentDependency>true</developmentDependency>
|
<developmentDependency>true</developmentDependency>
|
||||||
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
<requireLicenseAcceptance>false</requireLicenseAcceptance>
|
||||||
|
|||||||
Binary file not shown.
@@ -2,6 +2,7 @@
|
|||||||
using System.CommandLine.Invocation;
|
using System.CommandLine.Invocation;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using Windows.Management.Deployment;
|
using Windows.Management.Deployment;
|
||||||
|
|
||||||
@@ -75,6 +76,8 @@ internal static class Invocation
|
|||||||
Console.WriteLine("FamilyName not provided, enumerating packages.");
|
Console.WriteLine("FamilyName not provided, enumerating packages.");
|
||||||
|
|
||||||
foreach (Windows.ApplicationModel.Package package in packageManager.FindPackages())
|
foreach (Windows.ApplicationModel.Package package in packageManager.FindPackages())
|
||||||
|
{
|
||||||
|
try
|
||||||
{
|
{
|
||||||
if (package is { DisplayName: "Snap Hutao", PublisherDisplayName: "DGP Studio" })
|
if (package is { DisplayName: "Snap Hutao", PublisherDisplayName: "DGP Studio" })
|
||||||
{
|
{
|
||||||
@@ -82,6 +85,15 @@ internal static class Invocation
|
|||||||
Console.WriteLine($"Package found: {name}");
|
Console.WriteLine($"Package found: {name}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
catch (COMException ex)
|
||||||
|
{
|
||||||
|
// ERROR_MRM_MAP_NOT_FOUND
|
||||||
|
if (ex.HResult is not unchecked((int)0x80073B1F))
|
||||||
|
{
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Console.WriteLine("Starting app...");
|
Console.WriteLine("Starting app...");
|
||||||
|
|||||||
Reference in New Issue
Block a user