Skip to content

Commit

Permalink
Fix missing warning when using top menu umineko links (See #212)
Browse files Browse the repository at this point in the history
  • Loading branch information
drojf committed May 29, 2023
1 parent 5c10b96 commit 82e9829
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion httpGUI/python-patcher-index.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ window.onload = function onWindowLoaded() {
},
methods: {
nav(gameName) {
setModNameAndNavigate(gameName, gameName.toLowerCase().includes('umineko') ? 'umineko-warning.html' : 'installer.html');
setModNameAndNavigate(gameName);
},
// if subModExtraProperties missing a game, use wrong image
// to make it obvious that the table needs to be updated
Expand Down
4 changes: 2 additions & 2 deletions httpGUI/python-patcher-rest-lib.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,11 +103,11 @@ function doPost(requestType, requestData, onSuccessCallback, timeout, onErrorCal
}

// TODO: should always navigate to the same install page, as it is shared amongst all games
function setModNameAndNavigate(modName, targetURL) {
function setModNameAndNavigate(modName) {
doPost('setModName', { modName }, (response) => {
console.log(response);
if (response.valid) {
window.location.href = targetURL ?? 'installer.html';
window.location.href = modName.toLowerCase().includes('umineko') ? 'umineko-warning.html' : 'installer.html';
} else {
alert(`Error: "${modName}" is not the name of a mod in the JSON config file. Check web console for a list of valid mod names`);
console.error('Invalid Mod Name! Valid names below:');
Expand Down

0 comments on commit 82e9829

Please sign in to comment.