summaryrefslogtreecommitdiff
path: root/src/SMAPI.Web/Views/JsonValidator
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2019-12-01 22:24:01 -0500
committerJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2019-12-02 20:14:12 -0500
commit8a11d5c0d918264e95ddcdebd7dfa0554bccb216 (patch)
treeebaaa4b647e85789fc5ebd4f8399af3ad29ea73c /src/SMAPI.Web/Views/JsonValidator
parent5f532c259d5d3050bd6a053659067617db136d57 (diff)
downloadSMAPI-8a11d5c0d918264e95ddcdebd7dfa0554bccb216.tar.gz
SMAPI-8a11d5c0d918264e95ddcdebd7dfa0554bccb216.tar.bz2
SMAPI-8a11d5c0d918264e95ddcdebd7dfa0554bccb216.zip
fix incorrect link URLs in some cases
Diffstat (limited to 'src/SMAPI.Web/Views/JsonValidator')
-rw-r--r--src/SMAPI.Web/Views/JsonValidator/Index.cshtml9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/SMAPI.Web/Views/JsonValidator/Index.cshtml b/src/SMAPI.Web/Views/JsonValidator/Index.cshtml
index 41dec929..de6b06a2 100644
--- a/src/SMAPI.Web/Views/JsonValidator/Index.cshtml
+++ b/src/SMAPI.Web/Views/JsonValidator/Index.cshtml
@@ -1,10 +1,11 @@
+@using StardewModdingAPI.Web.Framework
@using StardewModdingAPI.Web.ViewModels.JsonValidator
@model JsonValidatorModel
@{
// get view data
- string curPageUrl = this.Url.Action("Index", "JsonValidator", new { schemaName = Model.SchemaName, id = Model.PasteID });
- string newUploadUrl = this.Url.Action("Index", "JsonValidator", new { schemaName = Model.SchemaName });
+ string curPageUrl = this.Url.PlainAction("Index", "JsonValidator", new { schemaName = Model.SchemaName, id = Model.PasteID });
+ string newUploadUrl = this.Url.PlainAction("Index", "JsonValidator", new { schemaName = Model.SchemaName });
string schemaDisplayName = null;
bool isValidSchema = Model.SchemaName != null && Model.SchemaFormats.TryGetValue(Model.SchemaName, out schemaDisplayName) && schemaDisplayName != "None";
@@ -35,7 +36,7 @@
<script src="~/Content/js/json-validator.js"></script>
<script>
$(function() {
- smapi.jsonValidator(@Json.Serialize(this.Url.Action("Index", "JsonValidator")), @Json.Serialize(Model.PasteID));
+ smapi.jsonValidator(@Json.Serialize(this.Url.PlainAction("Index", "JsonValidator", values: null)), @Json.Serialize(Model.PasteID));
});
</script>
}
@@ -70,7 +71,7 @@ else if (Model.PasteID != null)
@if (Model.Content == null)
{
<h2>Upload a JSON file</h2>
- <form action="@this.Url.Action("PostAsync", "JsonValidator")" method="post">
+ <form action="@this.Url.PlainAction("PostAsync", "JsonValidator")" method="post">
<ol>
<li>
Choose the JSON format:<br />