Fix character profile data fetching URL to correctly append the character ID and file extension
This commit is contained in:
parent
40ff7f5be7
commit
86d7a9215a
@ -15,7 +15,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
<script>
|
<script>
|
||||||
fetch("{{ '/assets/game-data/characters/' + include.id | relative_url }}")
|
fetch("{{ '/assets/game-data/characters/' | append: include.id | append: '.json' | relative_url }}")
|
||||||
.then(response => response.json())
|
.then(response => response.json())
|
||||||
.then(character => {
|
.then(character => {
|
||||||
document.getElementById('name-{{ include.id }}').innerText = character.name;
|
document.getElementById('name-{{ include.id }}').innerText = character.name;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user