Skip to content

Commit e6baa97

Browse files
Fixed error during update of a Git route. Pull needs a filled name and email. And these are not always filled in the routes.json. So hardcoded some values.
1 parent 0d6d045 commit e6baa97

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

Source/Menu/DownloadContentForm.cs

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -732,7 +732,7 @@ private bool infoChangedAndAddedFileForGitHubDownloadType(ContentRouteSettings.R
732732
}
733733
else
734734
{
735-
outputFile.WriteLine(Catalog.GetString("- No updates found") + "<br></p>");
735+
outputFile.WriteLine("- " + Catalog.GetString("No updates found") + "<br></p>");
736736
}
737737

738738
return changedFound && remoteUpdateFound;
@@ -980,10 +980,17 @@ private void updateButton_Click(object sender, EventArgs e)
980980
return;
981981
}
982982
}
983-
983+
if (doThePull(route))
984+
{
985+
message = Catalog.GetString("Updates installed");
986+
MessageBox.Show(message, Catalog.GetString("Attention"), MessageBoxButtons.OK, MessageBoxIcon.Information);
987+
}
988+
}
989+
else
990+
{
991+
message = Catalog.GetString("No updates found");
992+
MessageBox.Show(message, Catalog.GetString("Attention"), MessageBoxButtons.OK, MessageBoxIcon.Information);
984993
}
985-
986-
doThePull(route);
987994
}
988995

989996
private bool doThePull(ContentRouteSettings.Route route) {
@@ -997,7 +1004,7 @@ private bool doThePull(ContentRouteSettings.Route route) {
9971004

9981005
// User information to create a merge commit
9991006
var signature = new LibGit2Sharp.Signature(
1000-
new Identity(route.AuthorName, route.AuthorUrl), DateTimeOffset.Now);
1007+
new Identity("Open Rails", "www.openrails.org"), DateTimeOffset.Now);
10011008

10021009
// Pull
10031010
Commands.Pull(repo, signature, options);

0 commit comments

Comments
 (0)