Skip to content

Commit

Permalink
ConfigApp: Don't create duplicate submission item for local submissio…
Browse files Browse the repository at this point in the history
…n data
  • Loading branch information
pongo1231 committed Oct 30, 2023
1 parent d2734f7 commit ec32f00
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions ConfigApp/Tabs/WorkshopTab.cs
Original file line number Diff line number Diff line change
Expand Up @@ -88,19 +88,19 @@ T getDataItem<T>(dynamic item, T defaultValue)
var duplicateSubmissionItem = m_WorkshopSubmissionItems.FirstOrDefault((submissionItem) => { return submissionItem.Id == id; });
if (duplicateSubmissionItem != null)
{
if (!isLocal)
if (isLocal)
{
return;
if (duplicateSubmissionItem.Version != version || duplicateSubmissionItem.LastUpdated != lastUpdated || duplicateSubmissionItem.Sha256 != sha256)
{
duplicateSubmissionItem.InstallState = WorkshopSubmissionItem.SubmissionInstallState.UpdateAvailable;
}
else
{
duplicateSubmissionItem.InstallState = WorkshopSubmissionItem.SubmissionInstallState.Installed;
}
}

if (duplicateSubmissionItem.Version != version || duplicateSubmissionItem.LastUpdated != lastUpdated || duplicateSubmissionItem.Sha256 != sha256)
{
duplicateSubmissionItem.InstallState = WorkshopSubmissionItem.SubmissionInstallState.UpdateAvailable;
}
else
{
duplicateSubmissionItem.InstallState = WorkshopSubmissionItem.SubmissionInstallState.Installed;
}
return;
}

var submissionItem = new WorkshopSubmissionItem()
Expand Down

0 comments on commit ec32f00

Please sign in to comment.